/*
 * HIL_Interface.cs
 * Hardware-in-the-loop interface program for XPlane / Vexredus
 * Author: David Steenari (david [at] steenari [dot] se)
 * Version: 0.1 BETA
 */

// FIXME error handling / debug messages
// FIXME exceptions are waaaay to extensive, only use try/catch when needed? At least revise.

using System;

// For Winforms
using System.Drawing;
using System.Windows.Forms;

// Used for UDP networking 
using System.Net.Sockets;
using System.Net;

// Used for serial ports 
using System.IO.Ports;

// For message handling
using System.Text;

// For timed events
using System.Timers;

// For reading/writing config files
using System.IO;
using System.Xml;
using System.Xml.Serialization;

namespace VEXREDUS_hil_interface
{
	// Main window
	public class HIL_Interface : Form
	{
		#region Coded Attributes

        // Config File variables
        private const string HILConfigFileName = "HIL_Interface_config.xml";
        public HIL_Interface_Config HILConfig = new HIL_Interface_Config();
        private XmlSerializer HILConfigSerializer = new XmlSerializer(typeof(HIL_Interface_Config));

		// XPlane/Network variables
		private UdpClient XPlaneUDPOutput = new UdpClient(); // Socket used to receive OUTPUT data FROM XPlane
        private UdpClient XPlaneUDPInput = new UdpClient(); // Socket used to send INPUT data TO XPlane

		private int udp_received_num_bytes = 0; // Number of received bytes on UDP
        private int XPlaneNumReceivedMsgs = 0; // Number of received messages from XPlane
        private int XPlaneNumSentMsgs = 0;
		
		private XPlane_State xstate = new XPlane_State();
        private const float XPDATA_NOT_USED = (float)-999;
		
		// VexredusAPM/Serial port variables
		private SerialPort VxSerialPort = new SerialPort(); // Serial used to communicate with Vexredus APM
        private string VxSerialBuffer = "";
        private int VxSerialNumReceivedMsgs = 0;
        private int VxSerialNumSentMsgs = 0;

        // FIXME add vx_state class/struct
        private long vx_state_aileron = 0;
        private long vx_state_elevator = 0;

        // VexredusAPM/Serial port outputs
        private long VxSerialSendMessageGPSPeriod = 500; // 1 / 500 ms = 2 Hz
        private static System.Timers.Timer VxSerialSendMessageGPSTimer;
        #endregion

        // FIXME abstract this part
        #region protocol_settings
        private const char protocol_SOM = '$'; // Start-of-message
        private const char protocol_EOM = '\n'; // End-of-message
        private const char protocol_delim = ','; // Variable delimter
        private const char protocol_CRCdelim = '*'; // Checksum delimiter
        #endregion

        #region Attributes

        private MenuStrip menuStrip1;
        private ToolStripMenuItem fileToolStripMenuItem;
        private ToolStripMenuItem exitToolStripMenuItem;
        private ToolStripMenuItem editToolStripMenuItem;
        private ToolStripMenuItem helpToolStripMenuItem;
        private ToolStripMenuItem aboutToolStripMenuItem;
        private StatusStrip statusStrip1;
        private TabControl tabControl;
        private TabPage tabPageRawData;
        private TabPage tabPageDecodedData;
        private TabPage tabPageControls;
        private GroupBox groupBoxDataXPlane;
        private GroupBox groupBoxDataVexredus;
        private TableLayoutPanel tableLayoutPanelDataXPlane;
        private GroupBox groupBoxDataXPlaneDataGPS;
        private GroupBox groupBoxDataXPlaneAttitude;
        private TableLayoutPanel tableLayoutPanelDataXPlaneAttitude;
        private Label labelDataXPlaneAttitudeRoll;
        private TextBox textBoxXPlaneAttitudeRoll;
        private TextBox textBoxXPlaneAttitudePitch;
        private Label labelDataXPlaneAttitudePitch;
        private TextBox textBoxXPlaneAttitudeHeading;
        private Label labelDataXPlaneAttitudeHeading;
        private TableLayoutPanel tableLayoutPanelDataXPlanePosition;
        private Label labelDataXPlanePositionLatitude;
        private Label labelDataXPlanePositionLongitude;
        private Label labelDataXPlanePositionAltitude;
        private TextBox textBoxXPlaneGPSLatitude;
        private TextBox textBoxXPlaneGPSLongitude;
        private TextBox textBoxXPlaneGPSAltitude;
        private TableLayoutPanel tableLayoutPanelRawData;
        private GroupBox groupBoxRawXPlaneData;
        private GroupBox groupBoxRawVexredusData;
        private TextBox textBoxXPlaneRawData;
        private TextBox textBoxVexredusRawData;
        private GroupBox groupBoxDataXPlaneStatus;
        private TableLayoutPanel tableLayoutPanelDataVexredus;
        private GroupBox groupBoxDataVexredusStatus;
        private ToolStripStatusLabel toolStripStatusLabelXPlaneOutStatus;
        private TableLayoutPanel tableLayoutPanelDataXPlaneStatus;
        private Label labelDataXPlaneStatusReceivedNum;
        private TextBox textBoxXPlaneStatusSentNum;
        private TableLayoutPanel tableLayoutPanelControls;
        private GroupBox groupBoxControlsXPlane;
        private TableLayoutPanel tableLayoutPanelControlsXPlane;
        private GroupBox groupBoxControlsXPlanePosition;
        private TableLayoutPanel tableLayoutPanelControlsXPlanePosition;
        private Label labelControlsXPlanePositionLatitude;
        private Label labelControlsXPlanePositionLongitude;
        private Label labelControlsXPlanePositionAltitude;
        private TextBox textBoxControlsXPlanePositionLatitude;
        private TextBox textBoxControlsXPlanePositionLongitude;
        private TextBox textBoxControlsXPlanePositionAltitude;
        private Button buttonControlsXPlanePositionSet;
        private Label labelControlsXPlaneAttitudeHeading;
        private Label labelControlsXPlaneAttitudePitch;
        private Label labelControlsXPlaneAttitudeRoll;
        private TextBox textBoxControlsXPlaneAttitudeHeading;
        private TextBox textBoxControlsXPlaneAttitudePitch;
        private TextBox textBoxControlsXPlaneAttitudeRoll;
        private GroupBox groupBoxControlsXPlaneAttitude;
        private TableLayoutPanel tableLayoutPanelControlsXPlaneAttitude;
        private Button buttonControlsXPlaneAttitudeSet;
        private GroupBox groupBoxControlsXPlaneFlightControl;
        private TableLayoutPanel tableLayoutPanelControlsFlightControl;
        private Label labelControlsXPlaneFlightControlElevators;
        private Label labelControlsXPlaneFlightControlAilerons;
        private Label labelControlsXPlaneFlightControlRudder;
        private Button buttonControlsXPlaneFlightControlsSet;
        private TextBox textBoxControlsXPlaneFlightControlElevators;
        private TextBox textBoxControlsXPlaneFlightControlAilerons;
        private TextBox textBoxControlsXPlaneFlightControlRudder;
        private GroupBox groupBoxDataVexredusFlightControl;
        private TableLayoutPanel tableLayoutPanelDataVexredusFlightControl;
        private Label labelDataVexredusFlightControlAilerons;
        private Label labelDataVexredusFlightControlElevators;
        private TextBox textBoxDataVexredusFlightControlAilerons;
        private TextBox textBoxDataVexredusFlightControlElevators;
        private TableLayoutPanel tableLayoutPanelDataVexredusStatus;
        private Label labelDataVexredusStatusReceived;
        private TextBox textBoxDataVexredusStatusReceived;
        private GroupBox groupBoxDataXPlaneFlightControl;
        private TableLayoutPanel tableLayoutPanelDataXPlaneFlightControl;
        private Label labelDataXPlaneFlightControlAilerons;
        private TextBox textBoxDataXPlaneFlightControlAilerons;
        private TextBox textBoxDataXPlaneFlightControlElevators;
        private Label labelDataXPlaneFlightControlElevators;
        private TextBox textBoxDataXPlaneFlightControlRudder;
        private Label labelDataXPlaneFlightControlRudder;
        private TextBox textBoxXPlaneStatusReceivedNum;
        private Label labelDataXPlaneStatusSentNum;
        private Label labelDataVexredusStatusSent;
        private TextBox textBoxDataVexredusStatusSent;
        private ToolStripMenuItem connectionSettingsToolStripMenuItem;
        private ToolStripStatusLabel toolStripStatusLabelVexredusStatic;
        private ToolStripStatusLabel toolStripStatusLabelVexredusStatus;
        private TableLayoutPanel tableLayoutPanelConnection;
        private GroupBox groupBoxConnectionXPlane;
        private TableLayoutPanel tableLayoutPanelConnectionXPlane;
        private GroupBox groupBoxConnectionVexredus;
        private TableLayoutPanel tableLayoutPanelConnectionVexredus;
        private Button buttonConnectionVexredusConnect;
        private Button buttonConnectionVexredusDisconnect;
        private TableLayoutPanel tableLayoutPanelData;
        private Button buttonConnectionXPlaneConnect;
        private Button buttonConnectionXPlaneDisconnect;
        private Label labelConnectionXPlaneOutput;
        private Label labelConnectionXPlaneInput;
        private Label labelConnectionVexredusSerial;
        private Button buttonConnectionXPlaneListen;
        private Button buttonConnectionXPlaneStop;
        private ToolStripStatusLabel toolStripStatusLabelXPlaneInStatic;
        private ToolStripStatusLabel toolStripStatusLabelXPlaneInStatus;
        private ToolStripStatusLabel toolStripStatusLabelXPlaneOutStatic;
		
		#endregion
		
		#region Constructor
		public HIL_Interface()
		{
            HILConfigRead();

            // Main window
            this.Name = "Vexredus HIL Interface v0.1";
            this.Text = "Vexredus HIL Interface v0.1";

            // GUI stuff
			InitializeComponent();
            HILConfigUpdateGUI();
            
            // Button events
            exitToolStripMenuItem.Click += new EventHandler(exitButtonHandler);
            buttonConnectionVexredusConnect.Click += new EventHandler(VxSerialConnect);
            buttonConnectionVexredusDisconnect.Click += new EventHandler(VxSerialDisconnect);
            buttonConnectionXPlaneListen.Click += new EventHandler(XPlaneOutputListen);
            buttonConnectionXPlaneStop.Click += new EventHandler(XPlaneOutputStop);
            buttonConnectionXPlaneConnect.Click += new EventHandler(XPlaneInputConnect);
            buttonConnectionXPlaneDisconnect.Click += new EventHandler(XPlaneInputDisconnect);

			// Start the UDP Server for receiving from XPlane
            // FIXME temporary placement of connection initialization (control in program later)
            //this.Load += new System.EventHandler(this.XPlaneOutputListen);
            
            // Start the UDP Client to send to XPlane
            // FIXME temporary placement of UDP connection initialization (control in program later) + EVENTHANDLER
            //XPlaneUDPInput = new UdpClient(HILConfig.XPlaneUDPInputIP, HILConfig.XPlaneUDPInputPortNumber);

            // Set up the SerialPort to communicate to Vexredus APM with
            //VxSerialPort = new SerialPort();
            // FIXME temporary placement -- should be controlable from program UI
            //this.Load += new System.EventHandler(this.VxSerialConnect); // FIXME why as event?
            VxSerialPort.DataReceived += new SerialDataReceivedEventHandler(VxDataReceivedHandler); // Will be called in separate thread
            VxSerialPort.ErrorReceived += new SerialErrorReceivedEventHandler(VxErrorReceivedHandler);

            // GPS timed event
            VxSerialSendMessageGPSTimer = new System.Timers.Timer();
            VxSerialSendMessageGPSTimer.Elapsed += new ElapsedEventHandler(VxSerialSendMessageSimulationGPSElapsedEvent);
            VxSerialSendMessageGPSTimer.Interval = VxSerialSendMessageGPSPeriod;
		}
		#endregion
		
		#region Destructor
		~HIL_Interface()
		{
            // XPlane connections
			XPlaneUDPOutput.Close();
            XPlaneUDPInput.Close();

            // Vexredus connections
            if (VxSerialPort.IsOpen)
            {
                VxSerialPort.Close();
            }
		}
		
		#endregion
        #region Config methods
        public void HILConfigRead()
        {
            try
            {
                using (FileStream fr = File.OpenRead(HILConfigFileName))
                    HILConfig = HILConfigSerializer.Deserialize(fr) as HIL_Interface_Config;
            }
            catch (Exception ex)
            {
                System.Console.WriteLine("Error: HILConfigRead(): " + ex.Message);
                System.Console.WriteLine("Using empty/default configuration instead. Please save config from Connection Settings window.");
                HILConfig.XPlaneUDPOutputPortNumber = 49000;
                HILConfig.XPlaneUDPInputPortNumber = 49001;
                HILConfig.XPlaneUDPInputIP = "192.168.0.1";

                HILConfig.VxSerialPortName = "COM1";
                HILConfig.VxSerialPortBaudrate = 9600;
            }
        }

        public void HILConfigWrite()
        {
            try
            {
                using (FileStream fw = File.OpenWrite(HILConfigFileName))
                    HILConfigSerializer.Serialize(fw, HILConfig);
            }
            catch (Exception ex)
            {
                // DEBUGGING
                System.Console.WriteLine("Error: HILConfigWrite(): " + ex.Message);
            }
        }
        #endregion 
		
		#region Display methods
		private void XPlaneOutputDisplayStatusText(string text)
		{
            this.Invoke((MethodInvoker)delegate
            {
                toolStripStatusLabelXPlaneOutStatus.Text = text;
            });
		}

        private void XPlaneInputDisplayStatusText(string text)
        {
            this.Invoke((MethodInvoker)delegate
            {
                toolStripStatusLabelXPlaneInStatus.Text = text;
            });
        }
		
		private void XPlaneDisplayDataText(string text)
		{
            this.Invoke((MethodInvoker)delegate
            {
                textBoxXPlaneRawData.AppendText(text);
            });
		}

        private void XPlaneUpdateGUI()
        {
            // Invoke anonymous method on GUI thread
            this.Invoke((MethodInvoker)delegate
            {
                // Update number of received messages
                if (textBoxXPlaneStatusReceivedNum.Text != XPlaneNumReceivedMsgs.ToString())
                { textBoxXPlaneStatusReceivedNum.Text = XPlaneNumReceivedMsgs.ToString(); }

                // FIXME doesn't update on send calls, since this function is called when messages are received
                if (textBoxXPlaneStatusSentNum.Text != XPlaneNumSentMsgs.ToString())
                { textBoxXPlaneStatusSentNum.Text = XPlaneNumSentMsgs.ToString(); }

                // 11: flight con ail/elv/rud
                if (textBoxDataXPlaneFlightControlElevators.Text != xstate.elev.ToString())
                { textBoxDataXPlaneFlightControlElevators.Text = xstate.elev.ToString(); }

                if (textBoxDataXPlaneFlightControlAilerons.Text != xstate.ailrn.ToString())
                { textBoxDataXPlaneFlightControlAilerons.Text = xstate.ailrn.ToString(); }

                if (textBoxDataXPlaneFlightControlRudder.Text != xstate.ruddr.ToString())
                { textBoxDataXPlaneFlightControlRudder.Text = xstate.ruddr.ToString(); }

                // 18: pitch, roll, headings
                if (textBoxXPlaneAttitudeRoll.Text != xstate.roll.ToString())
                { textBoxXPlaneAttitudeRoll.Text = xstate.roll.ToString(); }

                if (textBoxXPlaneAttitudePitch.Text != xstate.pitch.ToString())
                { textBoxXPlaneAttitudePitch.Text = xstate.pitch.ToString(); }

                if (textBoxXPlaneAttitudeHeading.Text != xstate.hding_true.ToString())
                { textBoxXPlaneAttitudeHeading.Text = xstate.hding_true.ToString(); }

                // 20: lat, lon, altitude
                if (textBoxXPlaneGPSLatitude.Text != xstate.lat.ToString())
                { textBoxXPlaneGPSLatitude.Text = xstate.lat.ToString(); }

                if (textBoxXPlaneGPSLongitude.Text != xstate.lon.ToString())
                { textBoxXPlaneGPSLongitude.Text = xstate.lon.ToString(); }

                if (textBoxXPlaneGPSAltitude.Text != xstate.alt_ftmsl.ToString())
                { textBoxXPlaneGPSAltitude.Text = xstate.alt_ftmsl.ToString(); }
            });
        }

        private void VxSerialDisplayStatusText(string text)
        {
            this.Invoke((MethodInvoker)delegate
            {
                toolStripStatusLabelVexredusStatus.Text = text;
            });
        }

        private void VxSerialDisplayDataText(string text)
        {
            this.Invoke((MethodInvoker)delegate
            {
                textBoxVexredusRawData.AppendText(text);
            });
        }

        private void VxSerialUpdateGUI()
        {
            // Invoke anonymous method on GUI thread
            this.Invoke((MethodInvoker)delegate
            {
                // Update number of received messages
                if (textBoxDataVexredusStatusReceived.Text != VxSerialNumReceivedMsgs.ToString())
                { textBoxDataVexredusStatusReceived.Text = VxSerialNumReceivedMsgs.ToString(); }

                // FIXME doesn't update on send calls, since this function is called when messages are received
                if (textBoxDataVexredusStatusSent.Text != VxSerialNumSentMsgs.ToString())
                { textBoxDataVexredusStatusSent.Text = VxSerialNumSentMsgs.ToString(); }

                float elevator = vx_state_elevator / (float)500.0;
                float aileron = vx_state_aileron / (float)500.0;

                if (textBoxDataVexredusFlightControlElevators.Text != elevator.ToString())
                { textBoxDataVexredusFlightControlElevators.Text = elevator.ToString(); }

                if (textBoxDataVexredusFlightControlAilerons.Text != aileron.ToString())
                { textBoxDataVexredusFlightControlAilerons.Text = aileron.ToString(); }
            });
        }

        public void HILConfigUpdateGUI()
        {
            labelConnectionVexredusSerial.Text = "Serial Port: " + HILConfig.VxSerialPortName + " @ " + HILConfig.VxSerialPortBaudrate.ToString() + " baud";
            labelConnectionXPlaneInput.Text = "Input: " + HILConfig.XPlaneUDPInputIP + ":" + HILConfig.XPlaneUDPInputPortNumber.ToString();
            labelConnectionXPlaneOutput.Text = "Output port number: " + HILConfig.XPlaneUDPOutputPortNumber.ToString(); 
        }
		
		#endregion
		
		#region Events
        private void XPlaneOutputListen(object sender, EventArgs e)
        {
            try
            {
                // Start listening for UDP data
                XPlaneUDPOutput = new UdpClient(HILConfig.XPlaneUDPOutputPortNumber);
                XPlaneUDPOutput.BeginReceive(new AsyncCallback(XPlaneOutputReceiveData), null);

                buttonConnectionXPlaneListen.Enabled = false;
                buttonConnectionXPlaneStop.Enabled = true;
                XPlaneOutputDisplayStatusText("Listening on " + HILConfig.XPlaneUDPOutputPortNumber + ".");
            }
            catch (Exception ex)
            {
                this.XPlaneOutputDisplayStatusText("Error: XPlaneOutputListen(): " + ex.Message);
            }
        }

        private void XPlaneOutputStop(object sender, EventArgs e)
        {
            try
            {
                // FIXME this turns of the program, probably cause it might turn of while receiving
                XPlaneUDPOutput.Close();

                buttonConnectionXPlaneListen.Enabled = true;
                buttonConnectionXPlaneStop.Enabled = false;
                XPlaneOutputDisplayStatusText("Not listening.");
            }

            catch (Exception ex)
            {
                this.XPlaneOutputDisplayStatusText("Error: XPlaneOutputStop(): " + ex.Message);
            }
        }

        private void XPlaneInputConnect(object sender, EventArgs e)
        {
            //System.Console.WriteLine("debug: XPlaneInputConnect() called.");
            try
            {
                XPlaneUDPInput = new UdpClient(HILConfig.XPlaneUDPInputIP, HILConfig.XPlaneUDPInputPortNumber);
                // FIXME check if actually connected to host?

                buttonConnectionXPlaneConnect.Enabled = false;
                buttonConnectionXPlaneDisconnect.Enabled = true;
                XPlaneInputDisplayStatusText("Connected to: " + HILConfig.XPlaneUDPInputIP + ":" + HILConfig.XPlaneUDPInputPortNumber.ToString());
            }
            catch (Exception ex)
            {
                this.XPlaneInputDisplayStatusText("Error: XPlaneInputConnect(): " + ex.Message);
                System.Console.WriteLine("Error: XPlaneInputConnect(): " + ex.Message); // DEBUGGING
            }
        }

        private void XPlaneInputDisconnect(object sender, EventArgs e)
        {
            try
            {
                // FIXME implement

                buttonConnectionXPlaneConnect.Enabled = true;
                buttonConnectionXPlaneDisconnect.Enabled = false;
                XPlaneInputDisplayStatusText("Not connected.");
            }
            catch (Exception ex)
            {
                this.XPlaneInputDisplayStatusText("Error: XPlaneInputDisconnect(): " + ex.Message);
            }
        }
		
		private void VxSerialConnect(object sender, EventArgs e)
		{
			try
			{
                if (VxSerialPort.IsOpen)
                {
                    VxSerialPort.Close();
                }

                // Make sure a port is present
                if(VxSerialPort.PortName == "")
                {
                    VxSerialDisplayStatusText("error: couldn't connect to serial port!");
                    throw new System.Exception(); // FIXME better error handling
                }

                VxSerialPort.PortName = HILConfig.VxSerialPortName;
                VxSerialPort.BaudRate = HILConfig.VxSerialPortBaudrate;
                VxSerialPort.Parity = Parity.None;
                VxSerialPort.StopBits = StopBits.One;
                VxSerialPort.DataBits = 8;
                VxSerialPort.Handshake = Handshake.None;

                VxSerialPort.Open();

                if (VxSerialPort.IsOpen)
                {
                    // Update GUI
                    VxSerialDisplayStatusText("Connected.");
                    buttonConnectionVexredusConnect.Enabled = false;
                    buttonConnectionVexredusDisconnect.Enabled = true;

                    // Start the GPS timer event
                    VxSerialSendMessageGPSTimer.Enabled = true;
                }
                else
                {
                    // FIXME throw exception
                }

			}
			catch (Exception ex)
			{
				VxSerialDisplayStatusText ("Error: VxSerialConnect(): " + ex.Message);
                // DEBUGGING
                System.Console.WriteLine ("Error: VxSerialConnect(): " + ex.Message);
			}
		}

        private void VxSerialDisconnect(object sender, EventArgs e)
        {
            try
            {
                VxSerialPort.Close();

                // Turn of the GPS timer event
                VxSerialSendMessageGPSTimer.Enabled = false;

                // Update GUI
                VxSerialDisplayStatusText("Not connected.");
                buttonConnectionVexredusConnect.Enabled = true;
                buttonConnectionVexredusDisconnect.Enabled = false;
            }
            catch (Exception ex)
            {
                VxSerialDisplayStatusText("Error: VxSerialDisconnect(): " + ex.Message);
                // DEBUGGING
                System.Console.WriteLine("Error: VxSerialDisconnect(): " + ex.Message);
            }
        }

        private void VxDataReceivedHandler(object sender, SerialDataReceivedEventArgs e)
        {
            try
            {
                SerialPort sp = (SerialPort)sender;
                VxSerialMessage vxmsg;
                String VxSerialBuffer_save = "";
                String[] vxmsgs_s;

                VxSerialBuffer += sp.ReadExisting();
                 
                // Check for and delete any partialy received erronous message at the beginning of buffer
                if (VxSerialBuffer[0] != protocol_SOM)
                {
                    int msg_start = VxSerialBuffer.IndexOf(protocol_SOM);
                    VxSerialBuffer = VxSerialBuffer.Substring(msg_start);
                }

                // Check for partially received message at the end of inData
                if (VxSerialBuffer[VxSerialBuffer.Length - 1] != protocol_EOM)
                {
                    // Save last msg (part) for next event iteration
                    int lastmsg_i = VxSerialBuffer.LastIndexOf(protocol_EOM);
                    VxSerialBuffer_save = VxSerialBuffer.Substring(lastmsg_i);
                    VxSerialBuffer = VxSerialBuffer.Substring(0, (lastmsg_i+1));
                }

                // Split messages in to array and reset buffer
                vxmsgs_s = VxSerialBuffer.Split(new char[] {protocol_EOM}, StringSplitOptions.RemoveEmptyEntries);
                VxSerialBuffer = VxSerialBuffer_save;

                // Decode messages
                for (int i = 0; i < vxmsgs_s.Length; i++)
                {
                    vxmsg = new VxSerialMessage(vxmsgs_s[i] + protocol_EOM); // VxSerialMessage expects EOM at end
                    VxSerialMessageHandler(vxmsg);
                    VxSerialNumReceivedMsgs += 1;

                    //VxSerialUpdateGUI();
                    VxSerialDisplayDataText("[IN]: " + vxmsg.RawData);
                }

                // Update GUI only once per call (to not spawn to many tread invokes for high frequency messages)
                VxSerialUpdateGUI();
            }
            catch (Exception ex)
            {
                // FIXME implement
                System.Console.WriteLine("Error: VxDataReceivedHandler(): " + ex.Message);
            }
        }

        private void VxErrorReceivedHandler(object sender, SerialErrorReceivedEventArgs e)
        {
            SerialPort sp = (SerialPort)sender;
            System.Console.WriteLine("Error: VxErrorReceivedHandler() called.");
            
            // FIXME this is empty, so implement me maybe
        }
		
        // FIXME temporary hack
        private void VxSerialSendMessageSimulationGPSElapsedEvent(object source, ElapsedEventArgs e)
        {
            try
            {
                // double latitude, double longitude, double altitude, double heading, double speed
                // FIXME double check that the correct values are sent
                VxSerialSendMessageSimulationGPS(xstate.lat, xstate.lon, xstate.alt_ftmsl, xstate.hding_true, xstate.Vind_mph);
            }
            catch (Exception ex)
            {
                this.VxSerialDisplayStatusText("Error: VxSerialSendMessageSimulationGPSElapsedEvent(): " + ex.Message);
                // DEBUGGING
                System.Console.WriteLine("Error: VxSerialSendMessageSimulationGPSElapsedEvent(): " + ex.Message);
            }
        }
		#endregion
		
		#region Callbacks
		private void XPlaneOutputReceiveData(IAsyncResult asyncResult)
		{
			try
			{
				this.XPlaneOutputDisplayStatusText ("Receiving UDP data.");
				
				// Initialize remote endpoint and save received data
				IPEndPoint remote = new IPEndPoint(IPAddress.Any, 0);
				byte[] recvData = XPlaneUDPOutput.EndReceive(asyncResult, ref remote);
				
				// Update received bytes counter
				this.udp_received_num_bytes += recvData.Length;
				this.XPlaneDisplayDataText (Environment.NewLine + "Got " + recvData.Length + " bytes from " + remote.Address.ToString() + ".");
				
				// Decode the received data
				XPlaneDecodeReceivedData(recvData);
				
				// Restart listening for UDP data
				XPlaneUDPOutput.BeginReceive (XPlaneOutputReceiveData, null);
                this.XPlaneOutputDisplayStatusText("Listening on " + HILConfig.XPlaneUDPOutputPortNumber + ".");
			}
			catch (Exception ex)
			{
				this.XPlaneOutputDisplayStatusText ("Error: ReceiveData(): " + ex.Message);
				
				// Restart listening or UDP data anyway (to not block program) 
				// FIXME is this smart?
				XPlaneUDPOutput.BeginReceive (XPlaneOutputReceiveData, null);
			}
		}
		#endregion
		
		#region Methods
		// Decodes chunks of received data
		// FIXME add extra buffer (to be used for decoding next time) if data is cut in the middle of a msg
		private void XPlaneDecodeReceivedData(byte[] recvData)
		{
			try 
			{
				// Loop through the received data and gather messages
				int recvData_i = 0;
				int numXMsgs = (recvData.Length-5)/36; // Number of received (complete) messages

                // Update number of received messages
                XPlaneNumReceivedMsgs += numXMsgs;
				
				XPlane_UDP_Message[] recvXMsgs = new XPlane_UDP_Message[numXMsgs];
				int recvXMsgs_i = 0; // Index of received messages
				
				while(recvData_i < recvData.Length)
				{
					this.XPlaneOutputDisplayStatusText ("Decoding UDP messages, recvData_i = " + recvData_i.ToString ());
					
					byte[] currentMsg; 
					
					// Only the first seem to include the "DATA " header, msg_length = 41
					if(recvData_i == 0)
					{
						currentMsg = new byte[41];
						Array.Copy(recvData, recvData_i, currentMsg, 0, 41); // Copy the message w/ HEADER
						recvData_i += 41; // Skip to next message
					}
					// Rest of messages, msg_length = 36
					else
					{
						currentMsg = new byte[36];
						Array.Copy(recvData, recvData_i, currentMsg, 0, 36); // Copy the message
						recvData_i += 36; // Skip to next message
					}
					
					try {
						// Decode the current message
						XPlane_UDP_Message xmsg = new XPlane_UDP_Message(currentMsg);
						
						// Add to list of received messages
						// FIXME how to know that the messages was successfully decoded?
						recvXMsgs[recvXMsgs_i] = xmsg; 
						recvXMsgs_i++;
						
						// Display current message raw data
                        this.XPlaneDisplayDataText(Environment.NewLine + "RAW: " + xmsg.RawToString());
						
						// Output the message to the data box.
						this.XPlaneDisplayDataText(Environment.NewLine + "MSG: " + xmsg.DecodedToString());
					}
					catch (Exception ex)
					{
						this.XPlaneDisplayDataText ("Faulty message: " + ex.Message);
					}
				}
				
				// Handle the received messages
                XPlaneMessageHandler(recvXMsgs);

                // Update GUI with new messages
                XPlaneUpdateGUI();
			}
			catch (Exception ex)
			{
				this.XPlaneOutputDisplayStatusText ("Error: DecodeReceivedData(): " + ex.Message);
			}
		}
		
		/* XPlane UDP message handler
		 * 
		 * Added cases for the ones mentioned here: http://code.google.com/p/ardupilot-mega/wiki/Xplane
		 * Not all are used by the Vexredus autopilot though
		 * 
		 * Check XPlane_State class for variable explanations!
		 */
		private void XPlaneMessageHandler(XPlane_UDP_Message[] XMsgs)
		{
			// Loop over received messages
			for(int i=0;i<XMsgs.Length;i++) {
				switch(XMsgs[i].Index)
				{
				// 3: speeds
				case 3:
					xstate.Vind_kias = 		XMsgs[i].Vars[0];
					xstate.Vind_keas = 		XMsgs[i].Vars[1];
					xstate.Vtrue_ktas = 	XMsgs[i].Vars[2];
					xstate.Vtrue_ktgs = 	XMsgs[i].Vars[3];
											// 4: unused
					xstate.Vind_mph = 		XMsgs[i].Vars[5];
					xstate.Vtrue_mphas = 	XMsgs[i].Vars[6];
					xstate.Vtrue_mphgs = 	XMsgs[i].Vars[7];
					break;
					
				// 4: Mach, VVI, G-load
				case 4:
					xstate.Mach = 			XMsgs[i].Vars[0];
											// 1: unused
					xstate.VVI = 			XMsgs[i].Vars[2];
											// 3: unused
					xstate.Gload_norml = 	XMsgs[i].Vars[4];
					xstate.Gload_axial = 	XMsgs[i].Vars[5];
					xstate.Gload_side =		XMsgs[i].Vars[6];
											// 7: unused
					break;

                // 11: flight con ail/elv/rud
                case 11:
                    xstate.elev =           XMsgs[i].Vars[0];
                    xstate.ailrn =          XMsgs[i].Vars[1];
                    xstate.ruddr =          XMsgs[i].Vars[2];
                                            // 3: Unused
                    xstate.nwhel =          XMsgs[i].Vars[4];
                                            // 5: Unused
                                            // 6: Unused
                                            // 7: Unused
                    break;
				
				// 17: angular velocities
				case 17:
					xstate.Q = 				XMsgs[i].Vars[0];
					xstate.P = 				XMsgs[i].Vars[1];
					xstate.R = 				XMsgs[i].Vars[2];
											// 3: unused
											// 4: unused
											// 5: unused
											// 6: unused
											// 7: unused
					break;
				
				// 18: pitch, roll, headings
				case 18:
					xstate.pitch = 			XMsgs[i].Vars[0];
					xstate.roll = 			XMsgs[i].Vars[1];
					xstate.hding_true = 	XMsgs[i].Vars[2];
					xstate.hding_mag = 		XMsgs[i].Vars[3];
					xstate.mag = 			XMsgs[i].Vars[4];
											// 5: unused
											// 6: unused
					xstate.mavar = 			XMsgs[i].Vars[7];

                    // Update vx_ap as quickly as possible, for lowest latency
                    // Using variables from "case 17" as well, but those should just have been updated at this point anyway.
                    // FIXME yaw from AHRS isn't used is it? Skipping it to make message shorter (sent as GPS heading anyway)
                    VxSerialSendMessageSimulationAHRS(xstate.roll, xstate.pitch, 0, xstate.P, xstate.Q); 
                    break;
				
				// 19: AoA, side-slip, paths
				case 19:
					xstate.alpha = 			XMsgs[i].Vars[0];
					xstate.beta = 			XMsgs[i].Vars[1];
					xstate.hpath = 			XMsgs[i].Vars[2];
					xstate.vpath = 			XMsgs[i].Vars[3];
											// 4: unused
											// 5: unused
											// 6: unused
					xstate.slip = 			XMsgs[i].Vars[7];
					break;
				
				// 20: lat, lon, altitude
				case 20:
					xstate.lat = 			XMsgs[i].Vars[0];
					xstate.lon = 			XMsgs[i].Vars[1];
					xstate.alt_ftmsl = 		XMsgs[i].Vars[2];
					xstate.alt_ftagl = 		XMsgs[i].Vars[3];
					xstate.on = 			XMsgs[i].Vars[4];
					xstate.alt_ind = 		XMsgs[i].Vars[5];
					xstate.lat_south = 		XMsgs[i].Vars[6];
					xstate.lon_west = 		XMsgs[i].Vars[7];
					break;
				
				// Unknown/Non-implemented messages go here
				default:
					break;
				}
			}
		}

        private void XPlaneSendMessage(XPlane_UDP_Message xmsg_out)
        {
            try 
            {
                XPlaneUDPInput.Send(xmsg_out.RawData, xmsg_out.RawData.Length);

                XPlaneDisplayDataText(Environment.NewLine + "[OUT]: RAW: " + xmsg_out.RawToString());
                XPlaneDisplayDataText(Environment.NewLine + "[OUT]: MSG: " + xmsg_out.DecodedToString());

                XPlaneNumSentMsgs += 1;
            }
            catch (Exception ex)
            {
                this.XPlaneInputDisplayStatusText("Error: XPlaneSendMessage(): " + ex.Message);
                // DEBUGGING
                System.Console.WriteLine("Error: XPlaneSendMessage(): " + ex.Message);
            }
        }

        private void XPlaneSendMessageFlightControl(float elev, float ailrn, float ruddr)
        {
            try
            {
                // 11: flight con ail/elv/rud
                float[] vars_out = { elev, ailrn, ruddr, XPDATA_NOT_USED, XPDATA_NOT_USED, XPDATA_NOT_USED, XPDATA_NOT_USED, XPDATA_NOT_USED };
                XPlaneSendMessage(new XPlane_UDP_Message("DATA", 11, vars_out));

            }
            catch (Exception ex)
            {
                this.XPlaneInputDisplayStatusText("Error: XPlaneSendMessageFlightControl(): " + ex.Message);
                // DEBUGGING
                System.Console.WriteLine("Error: XPlaneSendMessageFlightControl(): " + ex.Message);
            }
        }

        // VxSerial message handler
        private void VxSerialMessageHandler(VxSerialMessage vxmsg)
        {
            try
            {
                switch (vxmsg.MsgType)
                {
                    // Flight Control message
                    case 'c':
                        //System.Console.WriteLine("VxSerial $c: Elevator: " + vxmsg.Vars[0] + ", Aileron: " + vxmsg.Vars[1]);
                        vx_state_elevator = vxmsg.Vars[0];
                        vx_state_aileron = vxmsg.Vars[1];

                        float elev_conv = vx_state_elevator;
                        float ailr_conv = vx_state_aileron;

                        elev_conv = elev_conv / (float)500.0;
                        ailr_conv = ailr_conv / (float)500.0;

                        // Send update to XPlane
                        XPlaneSendMessageFlightControl(elev_conv, ailr_conv, XPDATA_NOT_USED);
                        break;

                    default:
                        break;
                }
            }
            catch (Exception ex)
            {
                this.VxSerialDisplayStatusText("Error: VxSerialMessageHandler(): " + ex.Message);
                // DEBUGGING
                System.Console.WriteLine("Error: VxSerialMessageHandler(): " + ex.Message);
            }
        }

        private void VxSerialSendMessage(VxSerialMessage vxmsg_out)
        {
            try
            {
                if (!VxSerialPort.IsOpen)
                {
                    throw new System.Exception("Serial port not open.");
                }

                VxSerialPort.Write(vxmsg_out.RawData);
                VxSerialNumSentMsgs += 1;

                VxSerialDisplayDataText("[OUT]: " + vxmsg_out.RawData);
            }
            catch (Exception ex)
            {
                this.VxSerialDisplayStatusText("Error: VxSerialSendMessage(): " + ex.Message);
                // DEBUGGING
                System.Console.WriteLine("Error: VxSerialSendMessage(): " + ex.Message);
            }
        }

        /*
         * Parameters:
         * - Latitude: dd.DDDDDDD
         * - Longitude: dd.DDDDDDD
         * - Altitude: ft MSL
         * - Heading: dd.DD
         * - Speed: mph
         */
        private void VxSerialSendMessageSimulationGPS(double latitude, double longitude, double altitude, double heading, double speed)
        {
            try
            {
                long[] gps_vars = new long[5];
                double ft2cm = 30.48; // 1 foot = 30.48 cm
                double mph2cms = 44.70400; // 1 mph (miles/h) = 44.70400 cm/s

                gps_vars[0] = (long)(latitude * 10000000.0);    // LATITUDE: dd.DD... * 10^7
                gps_vars[1] = (long)(longitude * 10000000.0);   // LONGITUDE: dd.DD... * 10^7
                gps_vars[2] = (long)(altitude * ft2cm);         // ALTITUDE: feet MSL * [feet to cm]
                gps_vars[3] = (long)(heading * 100.0);          // HEADING: dd.DD... * 100
                gps_vars[4] = (long)(speed * mph2cms);          // SPEED: mph * [miles/h to cm/s]

                VxSerialMessage vxmsg_out = new VxSerialMessage('g', gps_vars);
                VxSerialSendMessage(vxmsg_out);
            }
            catch (Exception ex)
            {
                this.VxSerialDisplayStatusText("Error:VxSerialSendMessageSimulationGPS(): " + ex.Message);
                // DEBUGGING
                System.Console.WriteLine("Error: VxSerialSendMessageSimulationGPS(): " + ex.Message);
            }
        }

        /*
         * Parameters:
         * - roll: dd.DDDDDDD
         * - pitch: dd.DDDDDDD
         * - yaw: dd.DDDDDDD
         */
        private void VxSerialSendMessageSimulationAHRS(double roll, double pitch, double yaw, double rollrate, double pitchrate)
        {
            try
            {
                long[] ahrs_vars = new long[5];
                double deg2rad = 0.0174532925; // 1 degree = 0.0174532925 radians

                ahrs_vars[0] = (long)(roll * deg2rad * 100.0);  // ROLL: dd.DD... * [deg to rad] * 100
                ahrs_vars[1] = (long)(pitch * deg2rad * 100.0); // PITCH: dd.DD... * [deg to rad] * 100
                ahrs_vars[2] = (long)(yaw * deg2rad * 100.0);   // YAW: dd.DD... * [deg to rad] * 100

                ahrs_vars[3] = (long)(rollrate*1000);           // ROLLRATE: rad/s * 1000
                ahrs_vars[4] = (long)(pitchrate*1000);          // PITCHRATE: rad/s * 1000


                VxSerialSendMessage(new VxSerialMessage('a', ahrs_vars));
            }
            catch (Exception ex)
            {
                this.VxSerialDisplayStatusText("Error: VxSerialSendMessageSimulationAHRS(): " + ex.Message);
                // DEBUGGING
                System.Console.WriteLine("Error: VxSerialSendMessageSimulationAHRS(): " + ex.Message);
            }
        }



		#endregion

        // Added by the GUI Designer
        private void InitializeComponent()
        {
            this.menuStrip1 = new System.Windows.Forms.MenuStrip();
            this.fileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
            this.exitToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
            this.editToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
            this.connectionSettingsToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
            this.helpToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
            this.aboutToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
            this.statusStrip1 = new System.Windows.Forms.StatusStrip();
            this.toolStripStatusLabelXPlaneOutStatic = new System.Windows.Forms.ToolStripStatusLabel();
            this.toolStripStatusLabelXPlaneOutStatus = new System.Windows.Forms.ToolStripStatusLabel();
            this.toolStripStatusLabelXPlaneInStatic = new System.Windows.Forms.ToolStripStatusLabel();
            this.toolStripStatusLabelXPlaneInStatus = new System.Windows.Forms.ToolStripStatusLabel();
            this.toolStripStatusLabelVexredusStatic = new System.Windows.Forms.ToolStripStatusLabel();
            this.toolStripStatusLabelVexredusStatus = new System.Windows.Forms.ToolStripStatusLabel();
            this.tabControl = new System.Windows.Forms.TabControl();
            this.tabPageRawData = new System.Windows.Forms.TabPage();
            this.tableLayoutPanelRawData = new System.Windows.Forms.TableLayoutPanel();
            this.groupBoxRawXPlaneData = new System.Windows.Forms.GroupBox();
            this.textBoxXPlaneRawData = new System.Windows.Forms.TextBox();
            this.groupBoxRawVexredusData = new System.Windows.Forms.GroupBox();
            this.textBoxVexredusRawData = new System.Windows.Forms.TextBox();
            this.tabPageDecodedData = new System.Windows.Forms.TabPage();
            this.tableLayoutPanelData = new System.Windows.Forms.TableLayoutPanel();
            this.groupBoxDataVexredus = new System.Windows.Forms.GroupBox();
            this.tableLayoutPanelDataVexredus = new System.Windows.Forms.TableLayoutPanel();
            this.groupBoxDataVexredusStatus = new System.Windows.Forms.GroupBox();
            this.tableLayoutPanelDataVexredusStatus = new System.Windows.Forms.TableLayoutPanel();
            this.labelDataVexredusStatusReceived = new System.Windows.Forms.Label();
            this.textBoxDataVexredusStatusReceived = new System.Windows.Forms.TextBox();
            this.labelDataVexredusStatusSent = new System.Windows.Forms.Label();
            this.textBoxDataVexredusStatusSent = new System.Windows.Forms.TextBox();
            this.groupBoxDataVexredusFlightControl = new System.Windows.Forms.GroupBox();
            this.tableLayoutPanelDataVexredusFlightControl = new System.Windows.Forms.TableLayoutPanel();
            this.labelDataVexredusFlightControlAilerons = new System.Windows.Forms.Label();
            this.labelDataVexredusFlightControlElevators = new System.Windows.Forms.Label();
            this.textBoxDataVexredusFlightControlAilerons = new System.Windows.Forms.TextBox();
            this.textBoxDataVexredusFlightControlElevators = new System.Windows.Forms.TextBox();
            this.groupBoxDataXPlane = new System.Windows.Forms.GroupBox();
            this.tableLayoutPanelDataXPlane = new System.Windows.Forms.TableLayoutPanel();
            this.groupBoxDataXPlaneFlightControl = new System.Windows.Forms.GroupBox();
            this.tableLayoutPanelDataXPlaneFlightControl = new System.Windows.Forms.TableLayoutPanel();
            this.labelDataXPlaneFlightControlAilerons = new System.Windows.Forms.Label();
            this.textBoxDataXPlaneFlightControlAilerons = new System.Windows.Forms.TextBox();
            this.textBoxDataXPlaneFlightControlElevators = new System.Windows.Forms.TextBox();
            this.labelDataXPlaneFlightControlElevators = new System.Windows.Forms.Label();
            this.textBoxDataXPlaneFlightControlRudder = new System.Windows.Forms.TextBox();
            this.labelDataXPlaneFlightControlRudder = new System.Windows.Forms.Label();
            this.groupBoxDataXPlaneDataGPS = new System.Windows.Forms.GroupBox();
            this.tableLayoutPanelDataXPlanePosition = new System.Windows.Forms.TableLayoutPanel();
            this.labelDataXPlanePositionLatitude = new System.Windows.Forms.Label();
            this.labelDataXPlanePositionLongitude = new System.Windows.Forms.Label();
            this.labelDataXPlanePositionAltitude = new System.Windows.Forms.Label();
            this.textBoxXPlaneGPSLatitude = new System.Windows.Forms.TextBox();
            this.textBoxXPlaneGPSLongitude = new System.Windows.Forms.TextBox();
            this.textBoxXPlaneGPSAltitude = new System.Windows.Forms.TextBox();
            this.groupBoxDataXPlaneStatus = new System.Windows.Forms.GroupBox();
            this.tableLayoutPanelDataXPlaneStatus = new System.Windows.Forms.TableLayoutPanel();
            this.textBoxXPlaneStatusSentNum = new System.Windows.Forms.TextBox();
            this.labelDataXPlaneStatusReceivedNum = new System.Windows.Forms.Label();
            this.textBoxXPlaneStatusReceivedNum = new System.Windows.Forms.TextBox();
            this.labelDataXPlaneStatusSentNum = new System.Windows.Forms.Label();
            this.groupBoxDataXPlaneAttitude = new System.Windows.Forms.GroupBox();
            this.tableLayoutPanelDataXPlaneAttitude = new System.Windows.Forms.TableLayoutPanel();
            this.labelDataXPlaneAttitudeRoll = new System.Windows.Forms.Label();
            this.textBoxXPlaneAttitudeRoll = new System.Windows.Forms.TextBox();
            this.textBoxXPlaneAttitudePitch = new System.Windows.Forms.TextBox();
            this.labelDataXPlaneAttitudePitch = new System.Windows.Forms.Label();
            this.textBoxXPlaneAttitudeHeading = new System.Windows.Forms.TextBox();
            this.labelDataXPlaneAttitudeHeading = new System.Windows.Forms.Label();
            this.tabPageControls = new System.Windows.Forms.TabPage();
            this.tableLayoutPanelControls = new System.Windows.Forms.TableLayoutPanel();
            this.groupBoxControlsXPlane = new System.Windows.Forms.GroupBox();
            this.tableLayoutPanelControlsXPlane = new System.Windows.Forms.TableLayoutPanel();
            this.groupBoxControlsXPlanePosition = new System.Windows.Forms.GroupBox();
            this.tableLayoutPanelControlsXPlanePosition = new System.Windows.Forms.TableLayoutPanel();
            this.labelControlsXPlanePositionLatitude = new System.Windows.Forms.Label();
            this.labelControlsXPlanePositionLongitude = new System.Windows.Forms.Label();
            this.labelControlsXPlanePositionAltitude = new System.Windows.Forms.Label();
            this.textBoxControlsXPlanePositionLatitude = new System.Windows.Forms.TextBox();
            this.textBoxControlsXPlanePositionLongitude = new System.Windows.Forms.TextBox();
            this.textBoxControlsXPlanePositionAltitude = new System.Windows.Forms.TextBox();
            this.buttonControlsXPlanePositionSet = new System.Windows.Forms.Button();
            this.groupBoxControlsXPlaneFlightControl = new System.Windows.Forms.GroupBox();
            this.tableLayoutPanelControlsFlightControl = new System.Windows.Forms.TableLayoutPanel();
            this.labelControlsXPlaneFlightControlRudder = new System.Windows.Forms.Label();
            this.textBoxControlsXPlaneFlightControlRudder = new System.Windows.Forms.TextBox();
            this.textBoxControlsXPlaneFlightControlElevators = new System.Windows.Forms.TextBox();
            this.labelControlsXPlaneFlightControlElevators = new System.Windows.Forms.Label();
            this.labelControlsXPlaneFlightControlAilerons = new System.Windows.Forms.Label();
            this.textBoxControlsXPlaneFlightControlAilerons = new System.Windows.Forms.TextBox();
            this.buttonControlsXPlaneFlightControlsSet = new System.Windows.Forms.Button();
            this.groupBoxControlsXPlaneAttitude = new System.Windows.Forms.GroupBox();
            this.tableLayoutPanelControlsXPlaneAttitude = new System.Windows.Forms.TableLayoutPanel();
            this.labelControlsXPlaneAttitudePitch = new System.Windows.Forms.Label();
            this.textBoxControlsXPlaneAttitudePitch = new System.Windows.Forms.TextBox();
            this.buttonControlsXPlaneAttitudeSet = new System.Windows.Forms.Button();
            this.labelControlsXPlaneAttitudeHeading = new System.Windows.Forms.Label();
            this.textBoxControlsXPlaneAttitudeHeading = new System.Windows.Forms.TextBox();
            this.labelControlsXPlaneAttitudeRoll = new System.Windows.Forms.Label();
            this.textBoxControlsXPlaneAttitudeRoll = new System.Windows.Forms.TextBox();
            this.tableLayoutPanelConnection = new System.Windows.Forms.TableLayoutPanel();
            this.groupBoxConnectionXPlane = new System.Windows.Forms.GroupBox();
            this.tableLayoutPanelConnectionXPlane = new System.Windows.Forms.TableLayoutPanel();
            this.buttonConnectionXPlaneConnect = new System.Windows.Forms.Button();
            this.buttonConnectionXPlaneDisconnect = new System.Windows.Forms.Button();
            this.labelConnectionXPlaneOutput = new System.Windows.Forms.Label();
            this.labelConnectionXPlaneInput = new System.Windows.Forms.Label();
            this.buttonConnectionXPlaneListen = new System.Windows.Forms.Button();
            this.buttonConnectionXPlaneStop = new System.Windows.Forms.Button();
            this.groupBoxConnectionVexredus = new System.Windows.Forms.GroupBox();
            this.tableLayoutPanelConnectionVexredus = new System.Windows.Forms.TableLayoutPanel();
            this.buttonConnectionVexredusDisconnect = new System.Windows.Forms.Button();
            this.buttonConnectionVexredusConnect = new System.Windows.Forms.Button();
            this.labelConnectionVexredusSerial = new System.Windows.Forms.Label();
            this.menuStrip1.SuspendLayout();
            this.statusStrip1.SuspendLayout();
            this.tabControl.SuspendLayout();
            this.tabPageRawData.SuspendLayout();
            this.tableLayoutPanelRawData.SuspendLayout();
            this.groupBoxRawXPlaneData.SuspendLayout();
            this.groupBoxRawVexredusData.SuspendLayout();
            this.tabPageDecodedData.SuspendLayout();
            this.tableLayoutPanelData.SuspendLayout();
            this.groupBoxDataVexredus.SuspendLayout();
            this.tableLayoutPanelDataVexredus.SuspendLayout();
            this.groupBoxDataVexredusStatus.SuspendLayout();
            this.tableLayoutPanelDataVexredusStatus.SuspendLayout();
            this.groupBoxDataVexredusFlightControl.SuspendLayout();
            this.tableLayoutPanelDataVexredusFlightControl.SuspendLayout();
            this.groupBoxDataXPlane.SuspendLayout();
            this.tableLayoutPanelDataXPlane.SuspendLayout();
            this.groupBoxDataXPlaneFlightControl.SuspendLayout();
            this.tableLayoutPanelDataXPlaneFlightControl.SuspendLayout();
            this.groupBoxDataXPlaneDataGPS.SuspendLayout();
            this.tableLayoutPanelDataXPlanePosition.SuspendLayout();
            this.groupBoxDataXPlaneStatus.SuspendLayout();
            this.tableLayoutPanelDataXPlaneStatus.SuspendLayout();
            this.groupBoxDataXPlaneAttitude.SuspendLayout();
            this.tableLayoutPanelDataXPlaneAttitude.SuspendLayout();
            this.tabPageControls.SuspendLayout();
            this.tableLayoutPanelControls.SuspendLayout();
            this.groupBoxControlsXPlane.SuspendLayout();
            this.tableLayoutPanelControlsXPlane.SuspendLayout();
            this.groupBoxControlsXPlanePosition.SuspendLayout();
            this.tableLayoutPanelControlsXPlanePosition.SuspendLayout();
            this.groupBoxControlsXPlaneFlightControl.SuspendLayout();
            this.tableLayoutPanelControlsFlightControl.SuspendLayout();
            this.groupBoxControlsXPlaneAttitude.SuspendLayout();
            this.tableLayoutPanelControlsXPlaneAttitude.SuspendLayout();
            this.tableLayoutPanelConnection.SuspendLayout();
            this.groupBoxConnectionXPlane.SuspendLayout();
            this.tableLayoutPanelConnectionXPlane.SuspendLayout();
            this.groupBoxConnectionVexredus.SuspendLayout();
            this.tableLayoutPanelConnectionVexredus.SuspendLayout();
            this.SuspendLayout();
            // 
            // menuStrip1
            // 
            this.menuStrip1.BackColor = System.Drawing.SystemColors.MenuBar;
            this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
            this.fileToolStripMenuItem,
            this.editToolStripMenuItem,
            this.helpToolStripMenuItem});
            this.menuStrip1.Location = new System.Drawing.Point(0, 0);
            this.menuStrip1.Name = "menuStrip1";
            this.menuStrip1.Size = new System.Drawing.Size(813, 24);
            this.menuStrip1.TabIndex = 0;
            this.menuStrip1.Text = "menuStrip1";
            // 
            // fileToolStripMenuItem
            // 
            this.fileToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
            this.exitToolStripMenuItem});
            this.fileToolStripMenuItem.Name = "fileToolStripMenuItem";
            this.fileToolStripMenuItem.Size = new System.Drawing.Size(37, 20);
            this.fileToolStripMenuItem.Text = "File";
            // 
            // exitToolStripMenuItem
            // 
            this.exitToolStripMenuItem.Name = "exitToolStripMenuItem";
            this.exitToolStripMenuItem.Size = new System.Drawing.Size(92, 22);
            this.exitToolStripMenuItem.Text = "Exit";
            // 
            // editToolStripMenuItem
            // 
            this.editToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
            this.connectionSettingsToolStripMenuItem});
            this.editToolStripMenuItem.Name = "editToolStripMenuItem";
            this.editToolStripMenuItem.Size = new System.Drawing.Size(39, 20);
            this.editToolStripMenuItem.Text = "Edit";
            // 
            // connectionSettingsToolStripMenuItem
            // 
            this.connectionSettingsToolStripMenuItem.Name = "connectionSettingsToolStripMenuItem";
            this.connectionSettingsToolStripMenuItem.Size = new System.Drawing.Size(181, 22);
            this.connectionSettingsToolStripMenuItem.Text = "Connection Settings";
            this.connectionSettingsToolStripMenuItem.Click += new System.EventHandler(this.connectionSettingsToolStripMenuItem_Click);
            // 
            // helpToolStripMenuItem
            // 
            this.helpToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
            this.aboutToolStripMenuItem});
            this.helpToolStripMenuItem.Name = "helpToolStripMenuItem";
            this.helpToolStripMenuItem.Size = new System.Drawing.Size(44, 20);
            this.helpToolStripMenuItem.Text = "Help";
            // 
            // aboutToolStripMenuItem
            // 
            this.aboutToolStripMenuItem.Name = "aboutToolStripMenuItem";
            this.aboutToolStripMenuItem.Size = new System.Drawing.Size(107, 22);
            this.aboutToolStripMenuItem.Text = "About";
            this.aboutToolStripMenuItem.Click += new System.EventHandler(this.aboutToolStripMenuItem_Click);
            // 
            // statusStrip1
            // 
            this.statusStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
            this.toolStripStatusLabelXPlaneOutStatic,
            this.toolStripStatusLabelXPlaneOutStatus,
            this.toolStripStatusLabelXPlaneInStatic,
            this.toolStripStatusLabelXPlaneInStatus,
            this.toolStripStatusLabelVexredusStatic,
            this.toolStripStatusLabelVexredusStatus});
            this.statusStrip1.Location = new System.Drawing.Point(0, 519);
            this.statusStrip1.Name = "statusStrip1";
            this.statusStrip1.Size = new System.Drawing.Size(813, 22);
            this.statusStrip1.TabIndex = 1;
            this.statusStrip1.Text = "statusStrip1";
            // 
            // toolStripStatusLabelXPlaneOutStatic
            // 
            this.toolStripStatusLabelXPlaneOutStatic.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Italic);
            this.toolStripStatusLabelXPlaneOutStatic.Name = "toolStripStatusLabelXPlaneOutStatic";
            this.toolStripStatusLabelXPlaneOutStatic.Size = new System.Drawing.Size(70, 17);
            this.toolStripStatusLabelXPlaneOutStatic.Text = "XPlane Out:";
            // 
            // toolStripStatusLabelXPlaneOutStatus
            // 
            this.toolStripStatusLabelXPlaneOutStatus.AutoSize = false;
            this.toolStripStatusLabelXPlaneOutStatus.Name = "toolStripStatusLabelXPlaneOutStatus";
            this.toolStripStatusLabelXPlaneOutStatus.Size = new System.Drawing.Size(200, 17);
            this.toolStripStatusLabelXPlaneOutStatus.Text = "Not listening.";
            this.toolStripStatusLabelXPlaneOutStatus.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // toolStripStatusLabelXPlaneInStatic
            // 
            this.toolStripStatusLabelXPlaneInStatic.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Italic);
            this.toolStripStatusLabelXPlaneInStatic.Name = "toolStripStatusLabelXPlaneInStatic";
            this.toolStripStatusLabelXPlaneInStatic.Size = new System.Drawing.Size(60, 17);
            this.toolStripStatusLabelXPlaneInStatic.Text = "XPlane in:";
            // 
            // toolStripStatusLabelXPlaneInStatus
            // 
            this.toolStripStatusLabelXPlaneInStatus.AutoSize = false;
            this.toolStripStatusLabelXPlaneInStatus.Name = "toolStripStatusLabelXPlaneInStatus";
            this.toolStripStatusLabelXPlaneInStatus.Size = new System.Drawing.Size(200, 17);
            this.toolStripStatusLabelXPlaneInStatus.Text = "Not Connected.";
            this.toolStripStatusLabelXPlaneInStatus.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // toolStripStatusLabelVexredusStatic
            // 
            this.toolStripStatusLabelVexredusStatic.Font = new System.Drawing.Font("Segoe UI", 9F, System.Drawing.FontStyle.Italic);
            this.toolStripStatusLabelVexredusStatic.Name = "toolStripStatusLabelVexredusStatic";
            this.toolStripStatusLabelVexredusStatic.Size = new System.Drawing.Size(61, 17);
            this.toolStripStatusLabelVexredusStatic.Text = "Vexredus: ";
            // 
            // toolStripStatusLabelVexredusStatus
            // 
            this.toolStripStatusLabelVexredusStatus.AutoSize = false;
            this.toolStripStatusLabelVexredusStatus.Name = "toolStripStatusLabelVexredusStatus";
            this.toolStripStatusLabelVexredusStatus.Size = new System.Drawing.Size(200, 17);
            this.toolStripStatusLabelVexredusStatus.Text = "Not connected.";
            this.toolStripStatusLabelVexredusStatus.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // tabControl
            // 
            this.tabControl.Controls.Add(this.tabPageRawData);
            this.tabControl.Controls.Add(this.tabPageDecodedData);
            this.tabControl.Controls.Add(this.tabPageControls);
            this.tabControl.Location = new System.Drawing.Point(12, 27);
            this.tabControl.Name = "tabControl";
            this.tabControl.SelectedIndex = 0;
            this.tabControl.Size = new System.Drawing.Size(792, 407);
            this.tabControl.TabIndex = 2;
            // 
            // tabPageRawData
            // 
            this.tabPageRawData.BackColor = System.Drawing.SystemColors.ControlLight;
            this.tabPageRawData.Controls.Add(this.tableLayoutPanelRawData);
            this.tabPageRawData.Location = new System.Drawing.Point(4, 22);
            this.tabPageRawData.Name = "tabPageRawData";
            this.tabPageRawData.Padding = new System.Windows.Forms.Padding(3);
            this.tabPageRawData.Size = new System.Drawing.Size(784, 381);
            this.tabPageRawData.TabIndex = 0;
            this.tabPageRawData.Text = "Raw Data";
            // 
            // tableLayoutPanelRawData
            // 
            this.tableLayoutPanelRawData.ColumnCount = 1;
            this.tableLayoutPanelRawData.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelRawData.Controls.Add(this.groupBoxRawXPlaneData, 0, 0);
            this.tableLayoutPanelRawData.Controls.Add(this.groupBoxRawVexredusData, 0, 1);
            this.tableLayoutPanelRawData.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelRawData.Location = new System.Drawing.Point(3, 3);
            this.tableLayoutPanelRawData.Name = "tableLayoutPanelRawData";
            this.tableLayoutPanelRawData.RowCount = 2;
            this.tableLayoutPanelRawData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelRawData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelRawData.Size = new System.Drawing.Size(778, 375);
            this.tableLayoutPanelRawData.TabIndex = 0;
            // 
            // groupBoxRawXPlaneData
            // 
            this.groupBoxRawXPlaneData.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
            | System.Windows.Forms.AnchorStyles.Left) 
            | System.Windows.Forms.AnchorStyles.Right)));
            this.groupBoxRawXPlaneData.Controls.Add(this.textBoxXPlaneRawData);
            this.groupBoxRawXPlaneData.Location = new System.Drawing.Point(3, 3);
            this.groupBoxRawXPlaneData.Name = "groupBoxRawXPlaneData";
            this.groupBoxRawXPlaneData.Size = new System.Drawing.Size(772, 181);
            this.groupBoxRawXPlaneData.TabIndex = 0;
            this.groupBoxRawXPlaneData.TabStop = false;
            this.groupBoxRawXPlaneData.Text = "XPlane UDP Data";
            // 
            // textBoxXPlaneRawData
            // 
            this.textBoxXPlaneRawData.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
            | System.Windows.Forms.AnchorStyles.Left) 
            | System.Windows.Forms.AnchorStyles.Right)));
            this.textBoxXPlaneRawData.Location = new System.Drawing.Point(6, 19);
            this.textBoxXPlaneRawData.Multiline = true;
            this.textBoxXPlaneRawData.Name = "textBoxXPlaneRawData";
            this.textBoxXPlaneRawData.ReadOnly = true;
            this.textBoxXPlaneRawData.ScrollBars = System.Windows.Forms.ScrollBars.Vertical;
            this.textBoxXPlaneRawData.Size = new System.Drawing.Size(760, 156);
            this.textBoxXPlaneRawData.TabIndex = 0;
            // 
            // groupBoxRawVexredusData
            // 
            this.groupBoxRawVexredusData.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
            | System.Windows.Forms.AnchorStyles.Left) 
            | System.Windows.Forms.AnchorStyles.Right)));
            this.groupBoxRawVexredusData.Controls.Add(this.textBoxVexredusRawData);
            this.groupBoxRawVexredusData.Location = new System.Drawing.Point(3, 190);
            this.groupBoxRawVexredusData.Name = "groupBoxRawVexredusData";
            this.groupBoxRawVexredusData.Size = new System.Drawing.Size(772, 182);
            this.groupBoxRawVexredusData.TabIndex = 1;
            this.groupBoxRawVexredusData.TabStop = false;
            this.groupBoxRawVexredusData.Text = "Vexredus Serial Data";
            // 
            // textBoxVexredusRawData
            // 
            this.textBoxVexredusRawData.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
            | System.Windows.Forms.AnchorStyles.Left) 
            | System.Windows.Forms.AnchorStyles.Right)));
            this.textBoxVexredusRawData.Location = new System.Drawing.Point(6, 19);
            this.textBoxVexredusRawData.Multiline = true;
            this.textBoxVexredusRawData.Name = "textBoxVexredusRawData";
            this.textBoxVexredusRawData.ReadOnly = true;
            this.textBoxVexredusRawData.ScrollBars = System.Windows.Forms.ScrollBars.Vertical;
            this.textBoxVexredusRawData.Size = new System.Drawing.Size(760, 157);
            this.textBoxVexredusRawData.TabIndex = 0;
            // 
            // tabPageDecodedData
            // 
            this.tabPageDecodedData.BackColor = System.Drawing.SystemColors.ControlLight;
            this.tabPageDecodedData.Controls.Add(this.tableLayoutPanelData);
            this.tabPageDecodedData.Location = new System.Drawing.Point(4, 22);
            this.tabPageDecodedData.Name = "tabPageDecodedData";
            this.tabPageDecodedData.Padding = new System.Windows.Forms.Padding(3);
            this.tabPageDecodedData.Size = new System.Drawing.Size(784, 381);
            this.tabPageDecodedData.TabIndex = 1;
            this.tabPageDecodedData.Text = "Decoded Data";
            // 
            // tableLayoutPanelData
            // 
            this.tableLayoutPanelData.ColumnCount = 2;
            this.tableLayoutPanelData.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelData.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelData.Controls.Add(this.groupBoxDataVexredus, 1, 0);
            this.tableLayoutPanelData.Controls.Add(this.groupBoxDataXPlane, 0, 0);
            this.tableLayoutPanelData.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelData.Location = new System.Drawing.Point(3, 3);
            this.tableLayoutPanelData.Name = "tableLayoutPanelData";
            this.tableLayoutPanelData.RowCount = 1;
            this.tableLayoutPanelData.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelData.Size = new System.Drawing.Size(778, 375);
            this.tableLayoutPanelData.TabIndex = 0;
            // 
            // groupBoxDataVexredus
            // 
            this.groupBoxDataVexredus.Controls.Add(this.tableLayoutPanelDataVexredus);
            this.groupBoxDataVexredus.Dock = System.Windows.Forms.DockStyle.Fill;
            this.groupBoxDataVexredus.Location = new System.Drawing.Point(392, 3);
            this.groupBoxDataVexredus.Name = "groupBoxDataVexredus";
            this.groupBoxDataVexredus.Size = new System.Drawing.Size(383, 369);
            this.groupBoxDataVexredus.TabIndex = 0;
            this.groupBoxDataVexredus.TabStop = false;
            this.groupBoxDataVexredus.Text = "Vexredus";
            // 
            // tableLayoutPanelDataVexredus
            // 
            this.tableLayoutPanelDataVexredus.ColumnCount = 2;
            this.tableLayoutPanelDataVexredus.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataVexredus.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataVexredus.Controls.Add(this.groupBoxDataVexredusStatus, 0, 1);
            this.tableLayoutPanelDataVexredus.Controls.Add(this.groupBoxDataVexredusFlightControl, 0, 0);
            this.tableLayoutPanelDataVexredus.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelDataVexredus.Location = new System.Drawing.Point(3, 16);
            this.tableLayoutPanelDataVexredus.Name = "tableLayoutPanelDataVexredus";
            this.tableLayoutPanelDataVexredus.RowCount = 2;
            this.tableLayoutPanelDataVexredus.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataVexredus.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataVexredus.Size = new System.Drawing.Size(377, 350);
            this.tableLayoutPanelDataVexredus.TabIndex = 0;
            // 
            // groupBoxDataVexredusStatus
            // 
            this.groupBoxDataVexredusStatus.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
            | System.Windows.Forms.AnchorStyles.Left) 
            | System.Windows.Forms.AnchorStyles.Right)));
            this.groupBoxDataVexredusStatus.Controls.Add(this.tableLayoutPanelDataVexredusStatus);
            this.groupBoxDataVexredusStatus.Location = new System.Drawing.Point(3, 178);
            this.groupBoxDataVexredusStatus.Name = "groupBoxDataVexredusStatus";
            this.groupBoxDataVexredusStatus.Size = new System.Drawing.Size(182, 169);
            this.groupBoxDataVexredusStatus.TabIndex = 0;
            this.groupBoxDataVexredusStatus.TabStop = false;
            this.groupBoxDataVexredusStatus.Text = "Status";
            // 
            // tableLayoutPanelDataVexredusStatus
            // 
            this.tableLayoutPanelDataVexredusStatus.ColumnCount = 2;
            this.tableLayoutPanelDataVexredusStatus.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataVexredusStatus.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataVexredusStatus.Controls.Add(this.labelDataVexredusStatusReceived, 0, 1);
            this.tableLayoutPanelDataVexredusStatus.Controls.Add(this.textBoxDataVexredusStatusReceived, 1, 1);
            this.tableLayoutPanelDataVexredusStatus.Controls.Add(this.labelDataVexredusStatusSent, 0, 0);
            this.tableLayoutPanelDataVexredusStatus.Controls.Add(this.textBoxDataVexredusStatusSent, 1, 0);
            this.tableLayoutPanelDataVexredusStatus.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelDataVexredusStatus.Location = new System.Drawing.Point(3, 16);
            this.tableLayoutPanelDataVexredusStatus.Name = "tableLayoutPanelDataVexredusStatus";
            this.tableLayoutPanelDataVexredusStatus.RowCount = 3;
            this.tableLayoutPanelDataVexredusStatus.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataVexredusStatus.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataVexredusStatus.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 11F));
            this.tableLayoutPanelDataVexredusStatus.Size = new System.Drawing.Size(176, 150);
            this.tableLayoutPanelDataVexredusStatus.TabIndex = 0;
            // 
            // labelDataVexredusStatusReceived
            // 
            this.labelDataVexredusStatusReceived.AutoSize = true;
            this.labelDataVexredusStatusReceived.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataVexredusStatusReceived.Location = new System.Drawing.Point(3, 25);
            this.labelDataVexredusStatusReceived.Name = "labelDataVexredusStatusReceived";
            this.labelDataVexredusStatusReceived.Size = new System.Drawing.Size(82, 25);
            this.labelDataVexredusStatusReceived.TabIndex = 0;
            this.labelDataVexredusStatusReceived.Text = "Received:";
            this.labelDataVexredusStatusReceived.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxDataVexredusStatusReceived
            // 
            this.textBoxDataVexredusStatusReceived.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxDataVexredusStatusReceived.Location = new System.Drawing.Point(91, 28);
            this.textBoxDataVexredusStatusReceived.Name = "textBoxDataVexredusStatusReceived";
            this.textBoxDataVexredusStatusReceived.ReadOnly = true;
            this.textBoxDataVexredusStatusReceived.Size = new System.Drawing.Size(82, 20);
            this.textBoxDataVexredusStatusReceived.TabIndex = 2;
            // 
            // labelDataVexredusStatusSent
            // 
            this.labelDataVexredusStatusSent.AutoSize = true;
            this.labelDataVexredusStatusSent.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataVexredusStatusSent.Location = new System.Drawing.Point(3, 0);
            this.labelDataVexredusStatusSent.Name = "labelDataVexredusStatusSent";
            this.labelDataVexredusStatusSent.Size = new System.Drawing.Size(82, 25);
            this.labelDataVexredusStatusSent.TabIndex = 3;
            this.labelDataVexredusStatusSent.Text = "Sent:";
            this.labelDataVexredusStatusSent.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxDataVexredusStatusSent
            // 
            this.textBoxDataVexredusStatusSent.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxDataVexredusStatusSent.Location = new System.Drawing.Point(91, 3);
            this.textBoxDataVexredusStatusSent.Name = "textBoxDataVexredusStatusSent";
            this.textBoxDataVexredusStatusSent.ReadOnly = true;
            this.textBoxDataVexredusStatusSent.Size = new System.Drawing.Size(82, 20);
            this.textBoxDataVexredusStatusSent.TabIndex = 4;
            // 
            // groupBoxDataVexredusFlightControl
            // 
            this.groupBoxDataVexredusFlightControl.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
            | System.Windows.Forms.AnchorStyles.Left) 
            | System.Windows.Forms.AnchorStyles.Right)));
            this.groupBoxDataVexredusFlightControl.Controls.Add(this.tableLayoutPanelDataVexredusFlightControl);
            this.groupBoxDataVexredusFlightControl.Location = new System.Drawing.Point(3, 3);
            this.groupBoxDataVexredusFlightControl.Name = "groupBoxDataVexredusFlightControl";
            this.groupBoxDataVexredusFlightControl.Size = new System.Drawing.Size(182, 169);
            this.groupBoxDataVexredusFlightControl.TabIndex = 1;
            this.groupBoxDataVexredusFlightControl.TabStop = false;
            this.groupBoxDataVexredusFlightControl.Text = "Flight Control";
            // 
            // tableLayoutPanelDataVexredusFlightControl
            // 
            this.tableLayoutPanelDataVexredusFlightControl.ColumnCount = 2;
            this.tableLayoutPanelDataVexredusFlightControl.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataVexredusFlightControl.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataVexredusFlightControl.Controls.Add(this.labelDataVexredusFlightControlAilerons, 0, 0);
            this.tableLayoutPanelDataVexredusFlightControl.Controls.Add(this.labelDataVexredusFlightControlElevators, 0, 1);
            this.tableLayoutPanelDataVexredusFlightControl.Controls.Add(this.textBoxDataVexredusFlightControlAilerons, 1, 0);
            this.tableLayoutPanelDataVexredusFlightControl.Controls.Add(this.textBoxDataVexredusFlightControlElevators, 1, 1);
            this.tableLayoutPanelDataVexredusFlightControl.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelDataVexredusFlightControl.Location = new System.Drawing.Point(3, 16);
            this.tableLayoutPanelDataVexredusFlightControl.Name = "tableLayoutPanelDataVexredusFlightControl";
            this.tableLayoutPanelDataVexredusFlightControl.RowCount = 3;
            this.tableLayoutPanelDataVexredusFlightControl.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataVexredusFlightControl.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataVexredusFlightControl.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 17F));
            this.tableLayoutPanelDataVexredusFlightControl.Size = new System.Drawing.Size(176, 150);
            this.tableLayoutPanelDataVexredusFlightControl.TabIndex = 0;
            // 
            // labelDataVexredusFlightControlAilerons
            // 
            this.labelDataVexredusFlightControlAilerons.AutoSize = true;
            this.labelDataVexredusFlightControlAilerons.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataVexredusFlightControlAilerons.Location = new System.Drawing.Point(3, 0);
            this.labelDataVexredusFlightControlAilerons.Name = "labelDataVexredusFlightControlAilerons";
            this.labelDataVexredusFlightControlAilerons.Size = new System.Drawing.Size(82, 25);
            this.labelDataVexredusFlightControlAilerons.TabIndex = 0;
            this.labelDataVexredusFlightControlAilerons.Text = "Ailerons:";
            this.labelDataVexredusFlightControlAilerons.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // labelDataVexredusFlightControlElevators
            // 
            this.labelDataVexredusFlightControlElevators.AutoSize = true;
            this.labelDataVexredusFlightControlElevators.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataVexredusFlightControlElevators.Location = new System.Drawing.Point(3, 25);
            this.labelDataVexredusFlightControlElevators.Name = "labelDataVexredusFlightControlElevators";
            this.labelDataVexredusFlightControlElevators.Size = new System.Drawing.Size(82, 25);
            this.labelDataVexredusFlightControlElevators.TabIndex = 1;
            this.labelDataVexredusFlightControlElevators.Text = "Elevators:";
            this.labelDataVexredusFlightControlElevators.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxDataVexredusFlightControlAilerons
            // 
            this.textBoxDataVexredusFlightControlAilerons.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxDataVexredusFlightControlAilerons.Location = new System.Drawing.Point(91, 3);
            this.textBoxDataVexredusFlightControlAilerons.Name = "textBoxDataVexredusFlightControlAilerons";
            this.textBoxDataVexredusFlightControlAilerons.ReadOnly = true;
            this.textBoxDataVexredusFlightControlAilerons.Size = new System.Drawing.Size(82, 20);
            this.textBoxDataVexredusFlightControlAilerons.TabIndex = 2;
            // 
            // textBoxDataVexredusFlightControlElevators
            // 
            this.textBoxDataVexredusFlightControlElevators.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxDataVexredusFlightControlElevators.Location = new System.Drawing.Point(91, 28);
            this.textBoxDataVexredusFlightControlElevators.Name = "textBoxDataVexredusFlightControlElevators";
            this.textBoxDataVexredusFlightControlElevators.ReadOnly = true;
            this.textBoxDataVexredusFlightControlElevators.Size = new System.Drawing.Size(82, 20);
            this.textBoxDataVexredusFlightControlElevators.TabIndex = 3;
            // 
            // groupBoxDataXPlane
            // 
            this.groupBoxDataXPlane.Controls.Add(this.tableLayoutPanelDataXPlane);
            this.groupBoxDataXPlane.Dock = System.Windows.Forms.DockStyle.Fill;
            this.groupBoxDataXPlane.Location = new System.Drawing.Point(3, 3);
            this.groupBoxDataXPlane.Name = "groupBoxDataXPlane";
            this.groupBoxDataXPlane.Size = new System.Drawing.Size(383, 369);
            this.groupBoxDataXPlane.TabIndex = 0;
            this.groupBoxDataXPlane.TabStop = false;
            this.groupBoxDataXPlane.Text = "XPlane";
            // 
            // tableLayoutPanelDataXPlane
            // 
            this.tableLayoutPanelDataXPlane.ColumnCount = 2;
            this.tableLayoutPanelDataXPlane.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataXPlane.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataXPlane.Controls.Add(this.groupBoxDataXPlaneFlightControl, 1, 0);
            this.tableLayoutPanelDataXPlane.Controls.Add(this.groupBoxDataXPlaneDataGPS, 0, 0);
            this.tableLayoutPanelDataXPlane.Controls.Add(this.groupBoxDataXPlaneStatus, 0, 1);
            this.tableLayoutPanelDataXPlane.Controls.Add(this.groupBoxDataXPlaneAttitude, 1, 1);
            this.tableLayoutPanelDataXPlane.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelDataXPlane.Location = new System.Drawing.Point(3, 16);
            this.tableLayoutPanelDataXPlane.Name = "tableLayoutPanelDataXPlane";
            this.tableLayoutPanelDataXPlane.RowCount = 2;
            this.tableLayoutPanelDataXPlane.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataXPlane.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataXPlane.Size = new System.Drawing.Size(377, 350);
            this.tableLayoutPanelDataXPlane.TabIndex = 0;
            // 
            // groupBoxDataXPlaneFlightControl
            // 
            this.groupBoxDataXPlaneFlightControl.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
            | System.Windows.Forms.AnchorStyles.Left) 
            | System.Windows.Forms.AnchorStyles.Right)));
            this.groupBoxDataXPlaneFlightControl.Controls.Add(this.tableLayoutPanelDataXPlaneFlightControl);
            this.groupBoxDataXPlaneFlightControl.Location = new System.Drawing.Point(191, 3);
            this.groupBoxDataXPlaneFlightControl.Name = "groupBoxDataXPlaneFlightControl";
            this.groupBoxDataXPlaneFlightControl.Size = new System.Drawing.Size(183, 169);
            this.groupBoxDataXPlaneFlightControl.TabIndex = 3;
            this.groupBoxDataXPlaneFlightControl.TabStop = false;
            this.groupBoxDataXPlaneFlightControl.Text = "Flight Control";
            // 
            // tableLayoutPanelDataXPlaneFlightControl
            // 
            this.tableLayoutPanelDataXPlaneFlightControl.ColumnCount = 2;
            this.tableLayoutPanelDataXPlaneFlightControl.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataXPlaneFlightControl.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataXPlaneFlightControl.Controls.Add(this.labelDataXPlaneFlightControlAilerons, 0, 0);
            this.tableLayoutPanelDataXPlaneFlightControl.Controls.Add(this.textBoxDataXPlaneFlightControlAilerons, 1, 0);
            this.tableLayoutPanelDataXPlaneFlightControl.Controls.Add(this.textBoxDataXPlaneFlightControlElevators, 1, 1);
            this.tableLayoutPanelDataXPlaneFlightControl.Controls.Add(this.labelDataXPlaneFlightControlElevators, 0, 1);
            this.tableLayoutPanelDataXPlaneFlightControl.Controls.Add(this.textBoxDataXPlaneFlightControlRudder, 1, 2);
            this.tableLayoutPanelDataXPlaneFlightControl.Controls.Add(this.labelDataXPlaneFlightControlRudder, 0, 2);
            this.tableLayoutPanelDataXPlaneFlightControl.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelDataXPlaneFlightControl.Location = new System.Drawing.Point(3, 16);
            this.tableLayoutPanelDataXPlaneFlightControl.Name = "tableLayoutPanelDataXPlaneFlightControl";
            this.tableLayoutPanelDataXPlaneFlightControl.RowCount = 4;
            this.tableLayoutPanelDataXPlaneFlightControl.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataXPlaneFlightControl.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataXPlaneFlightControl.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataXPlaneFlightControl.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 86F));
            this.tableLayoutPanelDataXPlaneFlightControl.Size = new System.Drawing.Size(177, 150);
            this.tableLayoutPanelDataXPlaneFlightControl.TabIndex = 0;
            // 
            // labelDataXPlaneFlightControlAilerons
            // 
            this.labelDataXPlaneFlightControlAilerons.AutoSize = true;
            this.labelDataXPlaneFlightControlAilerons.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataXPlaneFlightControlAilerons.Location = new System.Drawing.Point(3, 0);
            this.labelDataXPlaneFlightControlAilerons.Name = "labelDataXPlaneFlightControlAilerons";
            this.labelDataXPlaneFlightControlAilerons.Size = new System.Drawing.Size(82, 25);
            this.labelDataXPlaneFlightControlAilerons.TabIndex = 0;
            this.labelDataXPlaneFlightControlAilerons.Text = "Ailerons:";
            this.labelDataXPlaneFlightControlAilerons.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxDataXPlaneFlightControlAilerons
            // 
            this.textBoxDataXPlaneFlightControlAilerons.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxDataXPlaneFlightControlAilerons.Location = new System.Drawing.Point(91, 3);
            this.textBoxDataXPlaneFlightControlAilerons.Name = "textBoxDataXPlaneFlightControlAilerons";
            this.textBoxDataXPlaneFlightControlAilerons.ReadOnly = true;
            this.textBoxDataXPlaneFlightControlAilerons.Size = new System.Drawing.Size(83, 20);
            this.textBoxDataXPlaneFlightControlAilerons.TabIndex = 1;
            // 
            // textBoxDataXPlaneFlightControlElevators
            // 
            this.textBoxDataXPlaneFlightControlElevators.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxDataXPlaneFlightControlElevators.Location = new System.Drawing.Point(91, 28);
            this.textBoxDataXPlaneFlightControlElevators.Name = "textBoxDataXPlaneFlightControlElevators";
            this.textBoxDataXPlaneFlightControlElevators.ReadOnly = true;
            this.textBoxDataXPlaneFlightControlElevators.Size = new System.Drawing.Size(83, 20);
            this.textBoxDataXPlaneFlightControlElevators.TabIndex = 2;
            // 
            // labelDataXPlaneFlightControlElevators
            // 
            this.labelDataXPlaneFlightControlElevators.AutoSize = true;
            this.labelDataXPlaneFlightControlElevators.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataXPlaneFlightControlElevators.Location = new System.Drawing.Point(3, 25);
            this.labelDataXPlaneFlightControlElevators.Name = "labelDataXPlaneFlightControlElevators";
            this.labelDataXPlaneFlightControlElevators.Size = new System.Drawing.Size(82, 25);
            this.labelDataXPlaneFlightControlElevators.TabIndex = 3;
            this.labelDataXPlaneFlightControlElevators.Text = "Elevators:";
            this.labelDataXPlaneFlightControlElevators.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxDataXPlaneFlightControlRudder
            // 
            this.textBoxDataXPlaneFlightControlRudder.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxDataXPlaneFlightControlRudder.Location = new System.Drawing.Point(91, 53);
            this.textBoxDataXPlaneFlightControlRudder.Name = "textBoxDataXPlaneFlightControlRudder";
            this.textBoxDataXPlaneFlightControlRudder.ReadOnly = true;
            this.textBoxDataXPlaneFlightControlRudder.Size = new System.Drawing.Size(83, 20);
            this.textBoxDataXPlaneFlightControlRudder.TabIndex = 4;
            // 
            // labelDataXPlaneFlightControlRudder
            // 
            this.labelDataXPlaneFlightControlRudder.AutoSize = true;
            this.labelDataXPlaneFlightControlRudder.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataXPlaneFlightControlRudder.Location = new System.Drawing.Point(3, 50);
            this.labelDataXPlaneFlightControlRudder.Name = "labelDataXPlaneFlightControlRudder";
            this.labelDataXPlaneFlightControlRudder.Size = new System.Drawing.Size(82, 25);
            this.labelDataXPlaneFlightControlRudder.TabIndex = 5;
            this.labelDataXPlaneFlightControlRudder.Text = "Rudder:";
            this.labelDataXPlaneFlightControlRudder.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // groupBoxDataXPlaneDataGPS
            // 
            this.groupBoxDataXPlaneDataGPS.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
            | System.Windows.Forms.AnchorStyles.Left) 
            | System.Windows.Forms.AnchorStyles.Right)));
            this.groupBoxDataXPlaneDataGPS.Controls.Add(this.tableLayoutPanelDataXPlanePosition);
            this.groupBoxDataXPlaneDataGPS.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.groupBoxDataXPlaneDataGPS.Location = new System.Drawing.Point(3, 3);
            this.groupBoxDataXPlaneDataGPS.Name = "groupBoxDataXPlaneDataGPS";
            this.groupBoxDataXPlaneDataGPS.Size = new System.Drawing.Size(182, 169);
            this.groupBoxDataXPlaneDataGPS.TabIndex = 0;
            this.groupBoxDataXPlaneDataGPS.TabStop = false;
            this.groupBoxDataXPlaneDataGPS.Text = "Position";
            // 
            // tableLayoutPanelDataXPlanePosition
            // 
            this.tableLayoutPanelDataXPlanePosition.ColumnCount = 2;
            this.tableLayoutPanelDataXPlanePosition.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataXPlanePosition.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataXPlanePosition.Controls.Add(this.labelDataXPlanePositionLatitude, 0, 0);
            this.tableLayoutPanelDataXPlanePosition.Controls.Add(this.labelDataXPlanePositionLongitude, 0, 1);
            this.tableLayoutPanelDataXPlanePosition.Controls.Add(this.labelDataXPlanePositionAltitude, 0, 2);
            this.tableLayoutPanelDataXPlanePosition.Controls.Add(this.textBoxXPlaneGPSLatitude, 1, 0);
            this.tableLayoutPanelDataXPlanePosition.Controls.Add(this.textBoxXPlaneGPSLongitude, 1, 1);
            this.tableLayoutPanelDataXPlanePosition.Controls.Add(this.textBoxXPlaneGPSAltitude, 1, 2);
            this.tableLayoutPanelDataXPlanePosition.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelDataXPlanePosition.Location = new System.Drawing.Point(3, 16);
            this.tableLayoutPanelDataXPlanePosition.Name = "tableLayoutPanelDataXPlanePosition";
            this.tableLayoutPanelDataXPlanePosition.RowCount = 4;
            this.tableLayoutPanelDataXPlanePosition.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataXPlanePosition.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataXPlanePosition.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataXPlanePosition.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 16F));
            this.tableLayoutPanelDataXPlanePosition.Size = new System.Drawing.Size(176, 150);
            this.tableLayoutPanelDataXPlanePosition.TabIndex = 0;
            // 
            // labelDataXPlanePositionLatitude
            // 
            this.labelDataXPlanePositionLatitude.AutoSize = true;
            this.labelDataXPlanePositionLatitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataXPlanePositionLatitude.Location = new System.Drawing.Point(3, 0);
            this.labelDataXPlanePositionLatitude.Name = "labelDataXPlanePositionLatitude";
            this.labelDataXPlanePositionLatitude.Size = new System.Drawing.Size(82, 25);
            this.labelDataXPlanePositionLatitude.TabIndex = 0;
            this.labelDataXPlanePositionLatitude.Text = "Latitude:";
            this.labelDataXPlanePositionLatitude.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // labelDataXPlanePositionLongitude
            // 
            this.labelDataXPlanePositionLongitude.AutoSize = true;
            this.labelDataXPlanePositionLongitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataXPlanePositionLongitude.Location = new System.Drawing.Point(3, 25);
            this.labelDataXPlanePositionLongitude.Name = "labelDataXPlanePositionLongitude";
            this.labelDataXPlanePositionLongitude.Size = new System.Drawing.Size(82, 25);
            this.labelDataXPlanePositionLongitude.TabIndex = 1;
            this.labelDataXPlanePositionLongitude.Text = "Longitude:";
            this.labelDataXPlanePositionLongitude.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // labelDataXPlanePositionAltitude
            // 
            this.labelDataXPlanePositionAltitude.AutoSize = true;
            this.labelDataXPlanePositionAltitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataXPlanePositionAltitude.Location = new System.Drawing.Point(3, 50);
            this.labelDataXPlanePositionAltitude.Name = "labelDataXPlanePositionAltitude";
            this.labelDataXPlanePositionAltitude.Size = new System.Drawing.Size(82, 25);
            this.labelDataXPlanePositionAltitude.TabIndex = 2;
            this.labelDataXPlanePositionAltitude.Text = "Altitude:";
            this.labelDataXPlanePositionAltitude.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxXPlaneGPSLatitude
            // 
            this.textBoxXPlaneGPSLatitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxXPlaneGPSLatitude.Location = new System.Drawing.Point(91, 3);
            this.textBoxXPlaneGPSLatitude.Name = "textBoxXPlaneGPSLatitude";
            this.textBoxXPlaneGPSLatitude.ReadOnly = true;
            this.textBoxXPlaneGPSLatitude.Size = new System.Drawing.Size(82, 20);
            this.textBoxXPlaneGPSLatitude.TabIndex = 6;
            // 
            // textBoxXPlaneGPSLongitude
            // 
            this.textBoxXPlaneGPSLongitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxXPlaneGPSLongitude.Location = new System.Drawing.Point(91, 28);
            this.textBoxXPlaneGPSLongitude.Name = "textBoxXPlaneGPSLongitude";
            this.textBoxXPlaneGPSLongitude.ReadOnly = true;
            this.textBoxXPlaneGPSLongitude.Size = new System.Drawing.Size(82, 20);
            this.textBoxXPlaneGPSLongitude.TabIndex = 7;
            // 
            // textBoxXPlaneGPSAltitude
            // 
            this.textBoxXPlaneGPSAltitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxXPlaneGPSAltitude.Location = new System.Drawing.Point(91, 53);
            this.textBoxXPlaneGPSAltitude.Name = "textBoxXPlaneGPSAltitude";
            this.textBoxXPlaneGPSAltitude.ReadOnly = true;
            this.textBoxXPlaneGPSAltitude.Size = new System.Drawing.Size(82, 20);
            this.textBoxXPlaneGPSAltitude.TabIndex = 8;
            // 
            // groupBoxDataXPlaneStatus
            // 
            this.groupBoxDataXPlaneStatus.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
            | System.Windows.Forms.AnchorStyles.Left) 
            | System.Windows.Forms.AnchorStyles.Right)));
            this.groupBoxDataXPlaneStatus.Controls.Add(this.tableLayoutPanelDataXPlaneStatus);
            this.groupBoxDataXPlaneStatus.Location = new System.Drawing.Point(3, 178);
            this.groupBoxDataXPlaneStatus.Name = "groupBoxDataXPlaneStatus";
            this.groupBoxDataXPlaneStatus.Size = new System.Drawing.Size(182, 169);
            this.groupBoxDataXPlaneStatus.TabIndex = 2;
            this.groupBoxDataXPlaneStatus.TabStop = false;
            this.groupBoxDataXPlaneStatus.Text = "Status";
            // 
            // tableLayoutPanelDataXPlaneStatus
            // 
            this.tableLayoutPanelDataXPlaneStatus.ColumnCount = 2;
            this.tableLayoutPanelDataXPlaneStatus.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataXPlaneStatus.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataXPlaneStatus.Controls.Add(this.textBoxXPlaneStatusSentNum, 1, 0);
            this.tableLayoutPanelDataXPlaneStatus.Controls.Add(this.labelDataXPlaneStatusReceivedNum, 0, 1);
            this.tableLayoutPanelDataXPlaneStatus.Controls.Add(this.textBoxXPlaneStatusReceivedNum, 1, 1);
            this.tableLayoutPanelDataXPlaneStatus.Controls.Add(this.labelDataXPlaneStatusSentNum, 0, 0);
            this.tableLayoutPanelDataXPlaneStatus.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelDataXPlaneStatus.Location = new System.Drawing.Point(3, 16);
            this.tableLayoutPanelDataXPlaneStatus.Name = "tableLayoutPanelDataXPlaneStatus";
            this.tableLayoutPanelDataXPlaneStatus.RowCount = 3;
            this.tableLayoutPanelDataXPlaneStatus.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataXPlaneStatus.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataXPlaneStatus.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 14F));
            this.tableLayoutPanelDataXPlaneStatus.Size = new System.Drawing.Size(176, 150);
            this.tableLayoutPanelDataXPlaneStatus.TabIndex = 0;
            // 
            // textBoxXPlaneStatusSentNum
            // 
            this.textBoxXPlaneStatusSentNum.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxXPlaneStatusSentNum.Location = new System.Drawing.Point(91, 3);
            this.textBoxXPlaneStatusSentNum.Name = "textBoxXPlaneStatusSentNum";
            this.textBoxXPlaneStatusSentNum.ReadOnly = true;
            this.textBoxXPlaneStatusSentNum.Size = new System.Drawing.Size(82, 20);
            this.textBoxXPlaneStatusSentNum.TabIndex = 1;
            // 
            // labelDataXPlaneStatusReceivedNum
            // 
            this.labelDataXPlaneStatusReceivedNum.AutoSize = true;
            this.labelDataXPlaneStatusReceivedNum.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataXPlaneStatusReceivedNum.Location = new System.Drawing.Point(3, 25);
            this.labelDataXPlaneStatusReceivedNum.Name = "labelDataXPlaneStatusReceivedNum";
            this.labelDataXPlaneStatusReceivedNum.Size = new System.Drawing.Size(82, 25);
            this.labelDataXPlaneStatusReceivedNum.TabIndex = 0;
            this.labelDataXPlaneStatusReceivedNum.Text = "Received:";
            this.labelDataXPlaneStatusReceivedNum.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxXPlaneStatusReceivedNum
            // 
            this.textBoxXPlaneStatusReceivedNum.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxXPlaneStatusReceivedNum.Location = new System.Drawing.Point(91, 28);
            this.textBoxXPlaneStatusReceivedNum.Name = "textBoxXPlaneStatusReceivedNum";
            this.textBoxXPlaneStatusReceivedNum.ReadOnly = true;
            this.textBoxXPlaneStatusReceivedNum.Size = new System.Drawing.Size(82, 20);
            this.textBoxXPlaneStatusReceivedNum.TabIndex = 2;
            // 
            // labelDataXPlaneStatusSentNum
            // 
            this.labelDataXPlaneStatusSentNum.AutoSize = true;
            this.labelDataXPlaneStatusSentNum.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataXPlaneStatusSentNum.Location = new System.Drawing.Point(3, 0);
            this.labelDataXPlaneStatusSentNum.Name = "labelDataXPlaneStatusSentNum";
            this.labelDataXPlaneStatusSentNum.Size = new System.Drawing.Size(82, 25);
            this.labelDataXPlaneStatusSentNum.TabIndex = 3;
            this.labelDataXPlaneStatusSentNum.Text = "Sent:";
            this.labelDataXPlaneStatusSentNum.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // groupBoxDataXPlaneAttitude
            // 
            this.groupBoxDataXPlaneAttitude.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
            | System.Windows.Forms.AnchorStyles.Left) 
            | System.Windows.Forms.AnchorStyles.Right)));
            this.groupBoxDataXPlaneAttitude.Controls.Add(this.tableLayoutPanelDataXPlaneAttitude);
            this.groupBoxDataXPlaneAttitude.Location = new System.Drawing.Point(191, 178);
            this.groupBoxDataXPlaneAttitude.Name = "groupBoxDataXPlaneAttitude";
            this.groupBoxDataXPlaneAttitude.Size = new System.Drawing.Size(183, 169);
            this.groupBoxDataXPlaneAttitude.TabIndex = 1;
            this.groupBoxDataXPlaneAttitude.TabStop = false;
            this.groupBoxDataXPlaneAttitude.Text = "Attitude";
            // 
            // tableLayoutPanelDataXPlaneAttitude
            // 
            this.tableLayoutPanelDataXPlaneAttitude.ColumnCount = 2;
            this.tableLayoutPanelDataXPlaneAttitude.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataXPlaneAttitude.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelDataXPlaneAttitude.Controls.Add(this.labelDataXPlaneAttitudeRoll, 0, 0);
            this.tableLayoutPanelDataXPlaneAttitude.Controls.Add(this.textBoxXPlaneAttitudeRoll, 1, 0);
            this.tableLayoutPanelDataXPlaneAttitude.Controls.Add(this.textBoxXPlaneAttitudePitch, 1, 1);
            this.tableLayoutPanelDataXPlaneAttitude.Controls.Add(this.labelDataXPlaneAttitudePitch, 0, 1);
            this.tableLayoutPanelDataXPlaneAttitude.Controls.Add(this.textBoxXPlaneAttitudeHeading, 1, 2);
            this.tableLayoutPanelDataXPlaneAttitude.Controls.Add(this.labelDataXPlaneAttitudeHeading, 0, 2);
            this.tableLayoutPanelDataXPlaneAttitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelDataXPlaneAttitude.Location = new System.Drawing.Point(3, 16);
            this.tableLayoutPanelDataXPlaneAttitude.Name = "tableLayoutPanelDataXPlaneAttitude";
            this.tableLayoutPanelDataXPlaneAttitude.RowCount = 4;
            this.tableLayoutPanelDataXPlaneAttitude.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataXPlaneAttitude.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataXPlaneAttitude.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelDataXPlaneAttitude.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 86F));
            this.tableLayoutPanelDataXPlaneAttitude.Size = new System.Drawing.Size(177, 150);
            this.tableLayoutPanelDataXPlaneAttitude.TabIndex = 0;
            // 
            // labelDataXPlaneAttitudeRoll
            // 
            this.labelDataXPlaneAttitudeRoll.AutoSize = true;
            this.labelDataXPlaneAttitudeRoll.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataXPlaneAttitudeRoll.Location = new System.Drawing.Point(3, 0);
            this.labelDataXPlaneAttitudeRoll.Name = "labelDataXPlaneAttitudeRoll";
            this.labelDataXPlaneAttitudeRoll.Size = new System.Drawing.Size(82, 25);
            this.labelDataXPlaneAttitudeRoll.TabIndex = 0;
            this.labelDataXPlaneAttitudeRoll.Text = "Roll:";
            this.labelDataXPlaneAttitudeRoll.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxXPlaneAttitudeRoll
            // 
            this.textBoxXPlaneAttitudeRoll.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxXPlaneAttitudeRoll.Location = new System.Drawing.Point(91, 3);
            this.textBoxXPlaneAttitudeRoll.Name = "textBoxXPlaneAttitudeRoll";
            this.textBoxXPlaneAttitudeRoll.ReadOnly = true;
            this.textBoxXPlaneAttitudeRoll.Size = new System.Drawing.Size(83, 20);
            this.textBoxXPlaneAttitudeRoll.TabIndex = 1;
            // 
            // textBoxXPlaneAttitudePitch
            // 
            this.textBoxXPlaneAttitudePitch.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxXPlaneAttitudePitch.Location = new System.Drawing.Point(91, 28);
            this.textBoxXPlaneAttitudePitch.Name = "textBoxXPlaneAttitudePitch";
            this.textBoxXPlaneAttitudePitch.ReadOnly = true;
            this.textBoxXPlaneAttitudePitch.Size = new System.Drawing.Size(83, 20);
            this.textBoxXPlaneAttitudePitch.TabIndex = 2;
            // 
            // labelDataXPlaneAttitudePitch
            // 
            this.labelDataXPlaneAttitudePitch.AutoSize = true;
            this.labelDataXPlaneAttitudePitch.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataXPlaneAttitudePitch.Location = new System.Drawing.Point(3, 25);
            this.labelDataXPlaneAttitudePitch.Name = "labelDataXPlaneAttitudePitch";
            this.labelDataXPlaneAttitudePitch.Size = new System.Drawing.Size(82, 25);
            this.labelDataXPlaneAttitudePitch.TabIndex = 3;
            this.labelDataXPlaneAttitudePitch.Text = "Pitch:";
            this.labelDataXPlaneAttitudePitch.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxXPlaneAttitudeHeading
            // 
            this.textBoxXPlaneAttitudeHeading.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxXPlaneAttitudeHeading.Location = new System.Drawing.Point(91, 53);
            this.textBoxXPlaneAttitudeHeading.Name = "textBoxXPlaneAttitudeHeading";
            this.textBoxXPlaneAttitudeHeading.ReadOnly = true;
            this.textBoxXPlaneAttitudeHeading.Size = new System.Drawing.Size(83, 20);
            this.textBoxXPlaneAttitudeHeading.TabIndex = 4;
            // 
            // labelDataXPlaneAttitudeHeading
            // 
            this.labelDataXPlaneAttitudeHeading.AutoSize = true;
            this.labelDataXPlaneAttitudeHeading.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelDataXPlaneAttitudeHeading.Location = new System.Drawing.Point(3, 50);
            this.labelDataXPlaneAttitudeHeading.Name = "labelDataXPlaneAttitudeHeading";
            this.labelDataXPlaneAttitudeHeading.Size = new System.Drawing.Size(82, 25);
            this.labelDataXPlaneAttitudeHeading.TabIndex = 5;
            this.labelDataXPlaneAttitudeHeading.Text = "Heading:";
            this.labelDataXPlaneAttitudeHeading.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // tabPageControls
            // 
            this.tabPageControls.BackColor = System.Drawing.SystemColors.ControlLight;
            this.tabPageControls.Controls.Add(this.tableLayoutPanelControls);
            this.tabPageControls.Location = new System.Drawing.Point(4, 22);
            this.tabPageControls.Name = "tabPageControls";
            this.tabPageControls.Padding = new System.Windows.Forms.Padding(3);
            this.tabPageControls.Size = new System.Drawing.Size(784, 381);
            this.tabPageControls.TabIndex = 2;
            this.tabPageControls.Text = "Controls";
            // 
            // tableLayoutPanelControls
            // 
            this.tableLayoutPanelControls.ColumnCount = 2;
            this.tableLayoutPanelControls.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelControls.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelControls.Controls.Add(this.groupBoxControlsXPlane, 0, 0);
            this.tableLayoutPanelControls.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelControls.Location = new System.Drawing.Point(3, 3);
            this.tableLayoutPanelControls.Name = "tableLayoutPanelControls";
            this.tableLayoutPanelControls.RowCount = 1;
            this.tableLayoutPanelControls.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
            this.tableLayoutPanelControls.Size = new System.Drawing.Size(778, 375);
            this.tableLayoutPanelControls.TabIndex = 0;
            // 
            // groupBoxControlsXPlane
            // 
            this.groupBoxControlsXPlane.Controls.Add(this.tableLayoutPanelControlsXPlane);
            this.groupBoxControlsXPlane.Dock = System.Windows.Forms.DockStyle.Fill;
            this.groupBoxControlsXPlane.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.groupBoxControlsXPlane.Location = new System.Drawing.Point(3, 3);
            this.groupBoxControlsXPlane.Name = "groupBoxControlsXPlane";
            this.groupBoxControlsXPlane.Size = new System.Drawing.Size(383, 369);
            this.groupBoxControlsXPlane.TabIndex = 0;
            this.groupBoxControlsXPlane.TabStop = false;
            this.groupBoxControlsXPlane.Text = "XPlane";
            // 
            // tableLayoutPanelControlsXPlane
            // 
            this.tableLayoutPanelControlsXPlane.ColumnCount = 2;
            this.tableLayoutPanelControlsXPlane.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelControlsXPlane.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelControlsXPlane.Controls.Add(this.groupBoxControlsXPlanePosition, 0, 0);
            this.tableLayoutPanelControlsXPlane.Controls.Add(this.groupBoxControlsXPlaneFlightControl, 1, 0);
            this.tableLayoutPanelControlsXPlane.Controls.Add(this.groupBoxControlsXPlaneAttitude, 1, 1);
            this.tableLayoutPanelControlsXPlane.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelControlsXPlane.Location = new System.Drawing.Point(3, 16);
            this.tableLayoutPanelControlsXPlane.Name = "tableLayoutPanelControlsXPlane";
            this.tableLayoutPanelControlsXPlane.RowCount = 2;
            this.tableLayoutPanelControlsXPlane.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50.13123F));
            this.tableLayoutPanelControlsXPlane.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 49.86877F));
            this.tableLayoutPanelControlsXPlane.Size = new System.Drawing.Size(377, 350);
            this.tableLayoutPanelControlsXPlane.TabIndex = 0;
            // 
            // groupBoxControlsXPlanePosition
            // 
            this.groupBoxControlsXPlanePosition.Controls.Add(this.tableLayoutPanelControlsXPlanePosition);
            this.groupBoxControlsXPlanePosition.Dock = System.Windows.Forms.DockStyle.Fill;
            this.groupBoxControlsXPlanePosition.Location = new System.Drawing.Point(3, 3);
            this.groupBoxControlsXPlanePosition.Name = "groupBoxControlsXPlanePosition";
            this.groupBoxControlsXPlanePosition.Size = new System.Drawing.Size(182, 169);
            this.groupBoxControlsXPlanePosition.TabIndex = 0;
            this.groupBoxControlsXPlanePosition.TabStop = false;
            this.groupBoxControlsXPlanePosition.Text = "Position";
            // 
            // tableLayoutPanelControlsXPlanePosition
            // 
            this.tableLayoutPanelControlsXPlanePosition.ColumnCount = 2;
            this.tableLayoutPanelControlsXPlanePosition.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelControlsXPlanePosition.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelControlsXPlanePosition.Controls.Add(this.labelControlsXPlanePositionLatitude, 0, 0);
            this.tableLayoutPanelControlsXPlanePosition.Controls.Add(this.labelControlsXPlanePositionLongitude, 0, 1);
            this.tableLayoutPanelControlsXPlanePosition.Controls.Add(this.labelControlsXPlanePositionAltitude, 0, 2);
            this.tableLayoutPanelControlsXPlanePosition.Controls.Add(this.textBoxControlsXPlanePositionLatitude, 1, 0);
            this.tableLayoutPanelControlsXPlanePosition.Controls.Add(this.textBoxControlsXPlanePositionLongitude, 1, 1);
            this.tableLayoutPanelControlsXPlanePosition.Controls.Add(this.textBoxControlsXPlanePositionAltitude, 1, 2);
            this.tableLayoutPanelControlsXPlanePosition.Controls.Add(this.buttonControlsXPlanePositionSet, 1, 3);
            this.tableLayoutPanelControlsXPlanePosition.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelControlsXPlanePosition.Location = new System.Drawing.Point(3, 16);
            this.tableLayoutPanelControlsXPlanePosition.Name = "tableLayoutPanelControlsXPlanePosition";
            this.tableLayoutPanelControlsXPlanePosition.RowCount = 5;
            this.tableLayoutPanelControlsXPlanePosition.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelControlsXPlanePosition.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelControlsXPlanePosition.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelControlsXPlanePosition.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 30F));
            this.tableLayoutPanelControlsXPlanePosition.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 22F));
            this.tableLayoutPanelControlsXPlanePosition.Size = new System.Drawing.Size(176, 150);
            this.tableLayoutPanelControlsXPlanePosition.TabIndex = 0;
            // 
            // labelControlsXPlanePositionLatitude
            // 
            this.labelControlsXPlanePositionLatitude.AutoSize = true;
            this.labelControlsXPlanePositionLatitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelControlsXPlanePositionLatitude.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.labelControlsXPlanePositionLatitude.Location = new System.Drawing.Point(3, 0);
            this.labelControlsXPlanePositionLatitude.Name = "labelControlsXPlanePositionLatitude";
            this.labelControlsXPlanePositionLatitude.Size = new System.Drawing.Size(82, 25);
            this.labelControlsXPlanePositionLatitude.TabIndex = 0;
            this.labelControlsXPlanePositionLatitude.Text = "Latitude:";
            this.labelControlsXPlanePositionLatitude.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // labelControlsXPlanePositionLongitude
            // 
            this.labelControlsXPlanePositionLongitude.AutoSize = true;
            this.labelControlsXPlanePositionLongitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelControlsXPlanePositionLongitude.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.labelControlsXPlanePositionLongitude.Location = new System.Drawing.Point(3, 25);
            this.labelControlsXPlanePositionLongitude.Name = "labelControlsXPlanePositionLongitude";
            this.labelControlsXPlanePositionLongitude.Size = new System.Drawing.Size(82, 25);
            this.labelControlsXPlanePositionLongitude.TabIndex = 1;
            this.labelControlsXPlanePositionLongitude.Text = "Longitude:";
            this.labelControlsXPlanePositionLongitude.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // labelControlsXPlanePositionAltitude
            // 
            this.labelControlsXPlanePositionAltitude.AutoSize = true;
            this.labelControlsXPlanePositionAltitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelControlsXPlanePositionAltitude.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.labelControlsXPlanePositionAltitude.Location = new System.Drawing.Point(3, 50);
            this.labelControlsXPlanePositionAltitude.Name = "labelControlsXPlanePositionAltitude";
            this.labelControlsXPlanePositionAltitude.Size = new System.Drawing.Size(82, 25);
            this.labelControlsXPlanePositionAltitude.TabIndex = 2;
            this.labelControlsXPlanePositionAltitude.Text = "Altitude:";
            this.labelControlsXPlanePositionAltitude.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxControlsXPlanePositionLatitude
            // 
            this.textBoxControlsXPlanePositionLatitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxControlsXPlanePositionLatitude.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.textBoxControlsXPlanePositionLatitude.Location = new System.Drawing.Point(91, 3);
            this.textBoxControlsXPlanePositionLatitude.Name = "textBoxControlsXPlanePositionLatitude";
            this.textBoxControlsXPlanePositionLatitude.Size = new System.Drawing.Size(82, 20);
            this.textBoxControlsXPlanePositionLatitude.TabIndex = 3;
            // 
            // textBoxControlsXPlanePositionLongitude
            // 
            this.textBoxControlsXPlanePositionLongitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxControlsXPlanePositionLongitude.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.textBoxControlsXPlanePositionLongitude.Location = new System.Drawing.Point(91, 28);
            this.textBoxControlsXPlanePositionLongitude.Name = "textBoxControlsXPlanePositionLongitude";
            this.textBoxControlsXPlanePositionLongitude.Size = new System.Drawing.Size(82, 20);
            this.textBoxControlsXPlanePositionLongitude.TabIndex = 4;
            // 
            // textBoxControlsXPlanePositionAltitude
            // 
            this.textBoxControlsXPlanePositionAltitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxControlsXPlanePositionAltitude.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.textBoxControlsXPlanePositionAltitude.Location = new System.Drawing.Point(91, 53);
            this.textBoxControlsXPlanePositionAltitude.Name = "textBoxControlsXPlanePositionAltitude";
            this.textBoxControlsXPlanePositionAltitude.Size = new System.Drawing.Size(82, 20);
            this.textBoxControlsXPlanePositionAltitude.TabIndex = 5;
            // 
            // buttonControlsXPlanePositionSet
            // 
            this.buttonControlsXPlanePositionSet.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.buttonControlsXPlanePositionSet.Location = new System.Drawing.Point(91, 78);
            this.buttonControlsXPlanePositionSet.Name = "buttonControlsXPlanePositionSet";
            this.buttonControlsXPlanePositionSet.Size = new System.Drawing.Size(57, 21);
            this.buttonControlsXPlanePositionSet.TabIndex = 6;
            this.buttonControlsXPlanePositionSet.Text = "Set";
            this.buttonControlsXPlanePositionSet.UseVisualStyleBackColor = true;
            this.buttonControlsXPlanePositionSet.Click += new System.EventHandler(this.buttonControlsXPlanePositionSet_Click);
            // 
            // groupBoxControlsXPlaneFlightControl
            // 
            this.groupBoxControlsXPlaneFlightControl.Controls.Add(this.tableLayoutPanelControlsFlightControl);
            this.groupBoxControlsXPlaneFlightControl.Dock = System.Windows.Forms.DockStyle.Fill;
            this.groupBoxControlsXPlaneFlightControl.Location = new System.Drawing.Point(191, 3);
            this.groupBoxControlsXPlaneFlightControl.Name = "groupBoxControlsXPlaneFlightControl";
            this.groupBoxControlsXPlaneFlightControl.Size = new System.Drawing.Size(183, 169);
            this.groupBoxControlsXPlaneFlightControl.TabIndex = 1;
            this.groupBoxControlsXPlaneFlightControl.TabStop = false;
            this.groupBoxControlsXPlaneFlightControl.Text = "Flight Control";
            // 
            // tableLayoutPanelControlsFlightControl
            // 
            this.tableLayoutPanelControlsFlightControl.ColumnCount = 2;
            this.tableLayoutPanelControlsFlightControl.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelControlsFlightControl.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelControlsFlightControl.Controls.Add(this.labelControlsXPlaneFlightControlRudder, 0, 2);
            this.tableLayoutPanelControlsFlightControl.Controls.Add(this.textBoxControlsXPlaneFlightControlRudder, 1, 2);
            this.tableLayoutPanelControlsFlightControl.Controls.Add(this.textBoxControlsXPlaneFlightControlElevators, 1, 1);
            this.tableLayoutPanelControlsFlightControl.Controls.Add(this.labelControlsXPlaneFlightControlElevators, 0, 1);
            this.tableLayoutPanelControlsFlightControl.Controls.Add(this.labelControlsXPlaneFlightControlAilerons, 0, 0);
            this.tableLayoutPanelControlsFlightControl.Controls.Add(this.textBoxControlsXPlaneFlightControlAilerons, 1, 0);
            this.tableLayoutPanelControlsFlightControl.Controls.Add(this.buttonControlsXPlaneFlightControlsSet, 1, 3);
            this.tableLayoutPanelControlsFlightControl.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelControlsFlightControl.Location = new System.Drawing.Point(3, 16);
            this.tableLayoutPanelControlsFlightControl.Name = "tableLayoutPanelControlsFlightControl";
            this.tableLayoutPanelControlsFlightControl.RowCount = 5;
            this.tableLayoutPanelControlsFlightControl.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelControlsFlightControl.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelControlsFlightControl.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelControlsFlightControl.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 30F));
            this.tableLayoutPanelControlsFlightControl.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 8F));
            this.tableLayoutPanelControlsFlightControl.Size = new System.Drawing.Size(177, 150);
            this.tableLayoutPanelControlsFlightControl.TabIndex = 0;
            // 
            // labelControlsXPlaneFlightControlRudder
            // 
            this.labelControlsXPlaneFlightControlRudder.AutoSize = true;
            this.labelControlsXPlaneFlightControlRudder.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelControlsXPlaneFlightControlRudder.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.labelControlsXPlaneFlightControlRudder.Location = new System.Drawing.Point(3, 50);
            this.labelControlsXPlaneFlightControlRudder.Name = "labelControlsXPlaneFlightControlRudder";
            this.labelControlsXPlaneFlightControlRudder.Size = new System.Drawing.Size(82, 25);
            this.labelControlsXPlaneFlightControlRudder.TabIndex = 2;
            this.labelControlsXPlaneFlightControlRudder.Text = "Rudder:";
            this.labelControlsXPlaneFlightControlRudder.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxControlsXPlaneFlightControlRudder
            // 
            this.textBoxControlsXPlaneFlightControlRudder.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxControlsXPlaneFlightControlRudder.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.textBoxControlsXPlaneFlightControlRudder.Location = new System.Drawing.Point(91, 53);
            this.textBoxControlsXPlaneFlightControlRudder.Name = "textBoxControlsXPlaneFlightControlRudder";
            this.textBoxControlsXPlaneFlightControlRudder.Size = new System.Drawing.Size(83, 20);
            this.textBoxControlsXPlaneFlightControlRudder.TabIndex = 5;
            // 
            // textBoxControlsXPlaneFlightControlElevators
            // 
            this.textBoxControlsXPlaneFlightControlElevators.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxControlsXPlaneFlightControlElevators.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.textBoxControlsXPlaneFlightControlElevators.Location = new System.Drawing.Point(91, 28);
            this.textBoxControlsXPlaneFlightControlElevators.Name = "textBoxControlsXPlaneFlightControlElevators";
            this.textBoxControlsXPlaneFlightControlElevators.Size = new System.Drawing.Size(83, 20);
            this.textBoxControlsXPlaneFlightControlElevators.TabIndex = 4;
            // 
            // labelControlsXPlaneFlightControlElevators
            // 
            this.labelControlsXPlaneFlightControlElevators.AutoSize = true;
            this.labelControlsXPlaneFlightControlElevators.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelControlsXPlaneFlightControlElevators.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.labelControlsXPlaneFlightControlElevators.Location = new System.Drawing.Point(3, 25);
            this.labelControlsXPlaneFlightControlElevators.Name = "labelControlsXPlaneFlightControlElevators";
            this.labelControlsXPlaneFlightControlElevators.Size = new System.Drawing.Size(82, 25);
            this.labelControlsXPlaneFlightControlElevators.TabIndex = 1;
            this.labelControlsXPlaneFlightControlElevators.Text = "Elevators:";
            this.labelControlsXPlaneFlightControlElevators.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // labelControlsXPlaneFlightControlAilerons
            // 
            this.labelControlsXPlaneFlightControlAilerons.AutoSize = true;
            this.labelControlsXPlaneFlightControlAilerons.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelControlsXPlaneFlightControlAilerons.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.labelControlsXPlaneFlightControlAilerons.Location = new System.Drawing.Point(3, 0);
            this.labelControlsXPlaneFlightControlAilerons.Name = "labelControlsXPlaneFlightControlAilerons";
            this.labelControlsXPlaneFlightControlAilerons.Size = new System.Drawing.Size(82, 25);
            this.labelControlsXPlaneFlightControlAilerons.TabIndex = 0;
            this.labelControlsXPlaneFlightControlAilerons.Text = "Ailerons:";
            this.labelControlsXPlaneFlightControlAilerons.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxControlsXPlaneFlightControlAilerons
            // 
            this.textBoxControlsXPlaneFlightControlAilerons.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxControlsXPlaneFlightControlAilerons.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.textBoxControlsXPlaneFlightControlAilerons.Location = new System.Drawing.Point(91, 3);
            this.textBoxControlsXPlaneFlightControlAilerons.Name = "textBoxControlsXPlaneFlightControlAilerons";
            this.textBoxControlsXPlaneFlightControlAilerons.Size = new System.Drawing.Size(83, 20);
            this.textBoxControlsXPlaneFlightControlAilerons.TabIndex = 3;
            // 
            // buttonControlsXPlaneFlightControlsSet
            // 
            this.buttonControlsXPlaneFlightControlsSet.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.buttonControlsXPlaneFlightControlsSet.Location = new System.Drawing.Point(91, 78);
            this.buttonControlsXPlaneFlightControlsSet.Name = "buttonControlsXPlaneFlightControlsSet";
            this.buttonControlsXPlaneFlightControlsSet.Size = new System.Drawing.Size(57, 23);
            this.buttonControlsXPlaneFlightControlsSet.TabIndex = 6;
            this.buttonControlsXPlaneFlightControlsSet.Text = "Set";
            this.buttonControlsXPlaneFlightControlsSet.UseVisualStyleBackColor = true;
            this.buttonControlsXPlaneFlightControlsSet.Click += new System.EventHandler(this.buttonControlsXPlaneFlightControlsSet_Click);
            // 
            // groupBoxControlsXPlaneAttitude
            // 
            this.groupBoxControlsXPlaneAttitude.Controls.Add(this.tableLayoutPanelControlsXPlaneAttitude);
            this.groupBoxControlsXPlaneAttitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.groupBoxControlsXPlaneAttitude.Location = new System.Drawing.Point(191, 178);
            this.groupBoxControlsXPlaneAttitude.Name = "groupBoxControlsXPlaneAttitude";
            this.groupBoxControlsXPlaneAttitude.Size = new System.Drawing.Size(183, 169);
            this.groupBoxControlsXPlaneAttitude.TabIndex = 2;
            this.groupBoxControlsXPlaneAttitude.TabStop = false;
            this.groupBoxControlsXPlaneAttitude.Text = "Attitude";
            // 
            // tableLayoutPanelControlsXPlaneAttitude
            // 
            this.tableLayoutPanelControlsXPlaneAttitude.ColumnCount = 2;
            this.tableLayoutPanelControlsXPlaneAttitude.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelControlsXPlaneAttitude.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelControlsXPlaneAttitude.Controls.Add(this.labelControlsXPlaneAttitudePitch, 0, 1);
            this.tableLayoutPanelControlsXPlaneAttitude.Controls.Add(this.textBoxControlsXPlaneAttitudePitch, 1, 1);
            this.tableLayoutPanelControlsXPlaneAttitude.Controls.Add(this.buttonControlsXPlaneAttitudeSet, 1, 3);
            this.tableLayoutPanelControlsXPlaneAttitude.Controls.Add(this.labelControlsXPlaneAttitudeHeading, 0, 2);
            this.tableLayoutPanelControlsXPlaneAttitude.Controls.Add(this.textBoxControlsXPlaneAttitudeHeading, 1, 2);
            this.tableLayoutPanelControlsXPlaneAttitude.Controls.Add(this.labelControlsXPlaneAttitudeRoll, 0, 0);
            this.tableLayoutPanelControlsXPlaneAttitude.Controls.Add(this.textBoxControlsXPlaneAttitudeRoll, 1, 0);
            this.tableLayoutPanelControlsXPlaneAttitude.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelControlsXPlaneAttitude.Location = new System.Drawing.Point(3, 16);
            this.tableLayoutPanelControlsXPlaneAttitude.Name = "tableLayoutPanelControlsXPlaneAttitude";
            this.tableLayoutPanelControlsXPlaneAttitude.RowCount = 5;
            this.tableLayoutPanelControlsXPlaneAttitude.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelControlsXPlaneAttitude.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelControlsXPlaneAttitude.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 25F));
            this.tableLayoutPanelControlsXPlaneAttitude.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 30F));
            this.tableLayoutPanelControlsXPlaneAttitude.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 18F));
            this.tableLayoutPanelControlsXPlaneAttitude.Size = new System.Drawing.Size(177, 150);
            this.tableLayoutPanelControlsXPlaneAttitude.TabIndex = 2;
            // 
            // labelControlsXPlaneAttitudePitch
            // 
            this.labelControlsXPlaneAttitudePitch.AutoSize = true;
            this.labelControlsXPlaneAttitudePitch.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelControlsXPlaneAttitudePitch.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.labelControlsXPlaneAttitudePitch.Location = new System.Drawing.Point(3, 25);
            this.labelControlsXPlaneAttitudePitch.Name = "labelControlsXPlaneAttitudePitch";
            this.labelControlsXPlaneAttitudePitch.Size = new System.Drawing.Size(82, 25);
            this.labelControlsXPlaneAttitudePitch.TabIndex = 1;
            this.labelControlsXPlaneAttitudePitch.Text = "Pitch:";
            this.labelControlsXPlaneAttitudePitch.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxControlsXPlaneAttitudePitch
            // 
            this.textBoxControlsXPlaneAttitudePitch.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxControlsXPlaneAttitudePitch.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.textBoxControlsXPlaneAttitudePitch.Location = new System.Drawing.Point(91, 28);
            this.textBoxControlsXPlaneAttitudePitch.Name = "textBoxControlsXPlaneAttitudePitch";
            this.textBoxControlsXPlaneAttitudePitch.Size = new System.Drawing.Size(83, 20);
            this.textBoxControlsXPlaneAttitudePitch.TabIndex = 4;
            // 
            // buttonControlsXPlaneAttitudeSet
            // 
            this.buttonControlsXPlaneAttitudeSet.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.buttonControlsXPlaneAttitudeSet.Location = new System.Drawing.Point(91, 78);
            this.buttonControlsXPlaneAttitudeSet.Name = "buttonControlsXPlaneAttitudeSet";
            this.buttonControlsXPlaneAttitudeSet.Size = new System.Drawing.Size(57, 22);
            this.buttonControlsXPlaneAttitudeSet.TabIndex = 6;
            this.buttonControlsXPlaneAttitudeSet.Text = "Set";
            this.buttonControlsXPlaneAttitudeSet.UseVisualStyleBackColor = true;
            this.buttonControlsXPlaneAttitudeSet.Click += new System.EventHandler(this.buttonControlsXPlaneAttitudeSet_Click);
            // 
            // labelControlsXPlaneAttitudeHeading
            // 
            this.labelControlsXPlaneAttitudeHeading.AutoSize = true;
            this.labelControlsXPlaneAttitudeHeading.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelControlsXPlaneAttitudeHeading.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.labelControlsXPlaneAttitudeHeading.Location = new System.Drawing.Point(3, 50);
            this.labelControlsXPlaneAttitudeHeading.Name = "labelControlsXPlaneAttitudeHeading";
            this.labelControlsXPlaneAttitudeHeading.Size = new System.Drawing.Size(82, 25);
            this.labelControlsXPlaneAttitudeHeading.TabIndex = 2;
            this.labelControlsXPlaneAttitudeHeading.Text = "Heading";
            this.labelControlsXPlaneAttitudeHeading.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxControlsXPlaneAttitudeHeading
            // 
            this.textBoxControlsXPlaneAttitudeHeading.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxControlsXPlaneAttitudeHeading.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.textBoxControlsXPlaneAttitudeHeading.Location = new System.Drawing.Point(91, 53);
            this.textBoxControlsXPlaneAttitudeHeading.Name = "textBoxControlsXPlaneAttitudeHeading";
            this.textBoxControlsXPlaneAttitudeHeading.Size = new System.Drawing.Size(83, 20);
            this.textBoxControlsXPlaneAttitudeHeading.TabIndex = 5;
            // 
            // labelControlsXPlaneAttitudeRoll
            // 
            this.labelControlsXPlaneAttitudeRoll.AutoSize = true;
            this.labelControlsXPlaneAttitudeRoll.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelControlsXPlaneAttitudeRoll.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.labelControlsXPlaneAttitudeRoll.Location = new System.Drawing.Point(3, 0);
            this.labelControlsXPlaneAttitudeRoll.Name = "labelControlsXPlaneAttitudeRoll";
            this.labelControlsXPlaneAttitudeRoll.Size = new System.Drawing.Size(82, 25);
            this.labelControlsXPlaneAttitudeRoll.TabIndex = 0;
            this.labelControlsXPlaneAttitudeRoll.Text = "Roll:";
            this.labelControlsXPlaneAttitudeRoll.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // textBoxControlsXPlaneAttitudeRoll
            // 
            this.textBoxControlsXPlaneAttitudeRoll.Dock = System.Windows.Forms.DockStyle.Fill;
            this.textBoxControlsXPlaneAttitudeRoll.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
            this.textBoxControlsXPlaneAttitudeRoll.Location = new System.Drawing.Point(91, 3);
            this.textBoxControlsXPlaneAttitudeRoll.Name = "textBoxControlsXPlaneAttitudeRoll";
            this.textBoxControlsXPlaneAttitudeRoll.Size = new System.Drawing.Size(83, 20);
            this.textBoxControlsXPlaneAttitudeRoll.TabIndex = 3;
            // 
            // tableLayoutPanelConnection
            // 
            this.tableLayoutPanelConnection.ColumnCount = 2;
            this.tableLayoutPanelConnection.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelConnection.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelConnection.Controls.Add(this.groupBoxConnectionXPlane, 0, 0);
            this.tableLayoutPanelConnection.Controls.Add(this.groupBoxConnectionVexredus, 1, 0);
            this.tableLayoutPanelConnection.Location = new System.Drawing.Point(12, 436);
            this.tableLayoutPanelConnection.Name = "tableLayoutPanelConnection";
            this.tableLayoutPanelConnection.RowCount = 1;
            this.tableLayoutPanelConnection.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 20F));
            this.tableLayoutPanelConnection.Size = new System.Drawing.Size(792, 78);
            this.tableLayoutPanelConnection.TabIndex = 3;
            // 
            // groupBoxConnectionXPlane
            // 
            this.groupBoxConnectionXPlane.Controls.Add(this.tableLayoutPanelConnectionXPlane);
            this.groupBoxConnectionXPlane.Dock = System.Windows.Forms.DockStyle.Fill;
            this.groupBoxConnectionXPlane.Location = new System.Drawing.Point(3, 3);
            this.groupBoxConnectionXPlane.Name = "groupBoxConnectionXPlane";
            this.groupBoxConnectionXPlane.Size = new System.Drawing.Size(390, 72);
            this.groupBoxConnectionXPlane.TabIndex = 0;
            this.groupBoxConnectionXPlane.TabStop = false;
            this.groupBoxConnectionXPlane.Text = "XPlane Connection";
            // 
            // tableLayoutPanelConnectionXPlane
            // 
            this.tableLayoutPanelConnectionXPlane.ColumnCount = 3;
            this.tableLayoutPanelConnectionXPlane.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 222F));
            this.tableLayoutPanelConnectionXPlane.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 81F));
            this.tableLayoutPanelConnectionXPlane.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 72F));
            this.tableLayoutPanelConnectionXPlane.Controls.Add(this.buttonConnectionXPlaneConnect, 1, 1);
            this.tableLayoutPanelConnectionXPlane.Controls.Add(this.buttonConnectionXPlaneDisconnect, 2, 1);
            this.tableLayoutPanelConnectionXPlane.Controls.Add(this.labelConnectionXPlaneOutput, 0, 0);
            this.tableLayoutPanelConnectionXPlane.Controls.Add(this.labelConnectionXPlaneInput, 0, 1);
            this.tableLayoutPanelConnectionXPlane.Controls.Add(this.buttonConnectionXPlaneListen, 1, 0);
            this.tableLayoutPanelConnectionXPlane.Controls.Add(this.buttonConnectionXPlaneStop, 2, 0);
            this.tableLayoutPanelConnectionXPlane.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelConnectionXPlane.Location = new System.Drawing.Point(3, 16);
            this.tableLayoutPanelConnectionXPlane.Name = "tableLayoutPanelConnectionXPlane";
            this.tableLayoutPanelConnectionXPlane.RowCount = 2;
            this.tableLayoutPanelConnectionXPlane.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelConnectionXPlane.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelConnectionXPlane.Size = new System.Drawing.Size(384, 53);
            this.tableLayoutPanelConnectionXPlane.TabIndex = 0;
            // 
            // buttonConnectionXPlaneConnect
            // 
            this.buttonConnectionXPlaneConnect.Location = new System.Drawing.Point(225, 29);
            this.buttonConnectionXPlaneConnect.Name = "buttonConnectionXPlaneConnect";
            this.buttonConnectionXPlaneConnect.Size = new System.Drawing.Size(75, 21);
            this.buttonConnectionXPlaneConnect.TabIndex = 2;
            this.buttonConnectionXPlaneConnect.Text = "Connect";
            this.buttonConnectionXPlaneConnect.UseVisualStyleBackColor = true;
            // 
            // buttonConnectionXPlaneDisconnect
            // 
            this.buttonConnectionXPlaneDisconnect.Enabled = false;
            this.buttonConnectionXPlaneDisconnect.Location = new System.Drawing.Point(306, 29);
            this.buttonConnectionXPlaneDisconnect.Name = "buttonConnectionXPlaneDisconnect";
            this.buttonConnectionXPlaneDisconnect.Size = new System.Drawing.Size(75, 21);
            this.buttonConnectionXPlaneDisconnect.TabIndex = 3;
            this.buttonConnectionXPlaneDisconnect.Text = "Disconnect";
            this.buttonConnectionXPlaneDisconnect.UseVisualStyleBackColor = true;
            // 
            // labelConnectionXPlaneOutput
            // 
            this.labelConnectionXPlaneOutput.AutoSize = true;
            this.labelConnectionXPlaneOutput.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelConnectionXPlaneOutput.Location = new System.Drawing.Point(3, 0);
            this.labelConnectionXPlaneOutput.Name = "labelConnectionXPlaneOutput";
            this.labelConnectionXPlaneOutput.Size = new System.Drawing.Size(216, 26);
            this.labelConnectionXPlaneOutput.TabIndex = 0;
            this.labelConnectionXPlaneOutput.Text = "Output port: [PORT]";
            this.labelConnectionXPlaneOutput.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // labelConnectionXPlaneInput
            // 
            this.labelConnectionXPlaneInput.AutoSize = true;
            this.labelConnectionXPlaneInput.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelConnectionXPlaneInput.Location = new System.Drawing.Point(3, 26);
            this.labelConnectionXPlaneInput.Name = "labelConnectionXPlaneInput";
            this.labelConnectionXPlaneInput.Size = new System.Drawing.Size(216, 27);
            this.labelConnectionXPlaneInput.TabIndex = 1;
            this.labelConnectionXPlaneInput.Text = "Input: [IP]:[PORT]";
            this.labelConnectionXPlaneInput.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // buttonConnectionXPlaneListen
            // 
            this.buttonConnectionXPlaneListen.Location = new System.Drawing.Point(225, 3);
            this.buttonConnectionXPlaneListen.Name = "buttonConnectionXPlaneListen";
            this.buttonConnectionXPlaneListen.Size = new System.Drawing.Size(75, 20);
            this.buttonConnectionXPlaneListen.TabIndex = 0;
            this.buttonConnectionXPlaneListen.Text = "Listen";
            this.buttonConnectionXPlaneListen.UseVisualStyleBackColor = true;
            // 
            // buttonConnectionXPlaneStop
            // 
            this.buttonConnectionXPlaneStop.Enabled = false;
            this.buttonConnectionXPlaneStop.Location = new System.Drawing.Point(306, 3);
            this.buttonConnectionXPlaneStop.Name = "buttonConnectionXPlaneStop";
            this.buttonConnectionXPlaneStop.Size = new System.Drawing.Size(75, 20);
            this.buttonConnectionXPlaneStop.TabIndex = 1;
            this.buttonConnectionXPlaneStop.Text = "Stop";
            this.buttonConnectionXPlaneStop.UseVisualStyleBackColor = true;
            // 
            // groupBoxConnectionVexredus
            // 
            this.groupBoxConnectionVexredus.Controls.Add(this.tableLayoutPanelConnectionVexredus);
            this.groupBoxConnectionVexredus.Dock = System.Windows.Forms.DockStyle.Fill;
            this.groupBoxConnectionVexredus.Location = new System.Drawing.Point(399, 3);
            this.groupBoxConnectionVexredus.Name = "groupBoxConnectionVexredus";
            this.groupBoxConnectionVexredus.Size = new System.Drawing.Size(390, 72);
            this.groupBoxConnectionVexredus.TabIndex = 1;
            this.groupBoxConnectionVexredus.TabStop = false;
            this.groupBoxConnectionVexredus.Text = "Vexredus Connection";
            // 
            // tableLayoutPanelConnectionVexredus
            // 
            this.tableLayoutPanelConnectionVexredus.ColumnCount = 3;
            this.tableLayoutPanelConnectionVexredus.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 222F));
            this.tableLayoutPanelConnectionVexredus.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 81F));
            this.tableLayoutPanelConnectionVexredus.ColumnStyles.Add(new System.Windows.Forms.ColumnStyle(System.Windows.Forms.SizeType.Absolute, 9F));
            this.tableLayoutPanelConnectionVexredus.Controls.Add(this.buttonConnectionVexredusDisconnect, 2, 1);
            this.tableLayoutPanelConnectionVexredus.Controls.Add(this.buttonConnectionVexredusConnect, 1, 1);
            this.tableLayoutPanelConnectionVexredus.Controls.Add(this.labelConnectionVexredusSerial, 0, 1);
            this.tableLayoutPanelConnectionVexredus.Dock = System.Windows.Forms.DockStyle.Fill;
            this.tableLayoutPanelConnectionVexredus.Location = new System.Drawing.Point(3, 16);
            this.tableLayoutPanelConnectionVexredus.Name = "tableLayoutPanelConnectionVexredus";
            this.tableLayoutPanelConnectionVexredus.RowCount = 2;
            this.tableLayoutPanelConnectionVexredus.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelConnectionVexredus.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 50F));
            this.tableLayoutPanelConnectionVexredus.Size = new System.Drawing.Size(384, 53);
            this.tableLayoutPanelConnectionVexredus.TabIndex = 0;
            // 
            // buttonConnectionVexredusDisconnect
            // 
            this.buttonConnectionVexredusDisconnect.Enabled = false;
            this.buttonConnectionVexredusDisconnect.Location = new System.Drawing.Point(306, 29);
            this.buttonConnectionVexredusDisconnect.Name = "buttonConnectionVexredusDisconnect";
            this.buttonConnectionVexredusDisconnect.Size = new System.Drawing.Size(75, 21);
            this.buttonConnectionVexredusDisconnect.TabIndex = 2;
            this.buttonConnectionVexredusDisconnect.Text = "Disconnect";
            this.buttonConnectionVexredusDisconnect.UseVisualStyleBackColor = true;
            // 
            // buttonConnectionVexredusConnect
            // 
            this.buttonConnectionVexredusConnect.Location = new System.Drawing.Point(225, 29);
            this.buttonConnectionVexredusConnect.Name = "buttonConnectionVexredusConnect";
            this.buttonConnectionVexredusConnect.Size = new System.Drawing.Size(75, 21);
            this.buttonConnectionVexredusConnect.TabIndex = 1;
            this.buttonConnectionVexredusConnect.Text = "Connect";
            this.buttonConnectionVexredusConnect.UseVisualStyleBackColor = true;
            // 
            // labelConnectionVexredusSerial
            // 
            this.labelConnectionVexredusSerial.AutoSize = true;
            this.labelConnectionVexredusSerial.Dock = System.Windows.Forms.DockStyle.Fill;
            this.labelConnectionVexredusSerial.Location = new System.Drawing.Point(3, 26);
            this.labelConnectionVexredusSerial.Name = "labelConnectionVexredusSerial";
            this.labelConnectionVexredusSerial.Size = new System.Drawing.Size(216, 27);
            this.labelConnectionVexredusSerial.TabIndex = 0;
            this.labelConnectionVexredusSerial.Text = "Serial Port: ??? @ ??? baud";
            this.labelConnectionVexredusSerial.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
            // 
            // HIL_Interface
            // 
            this.BackColor = System.Drawing.SystemColors.ControlLight;
            this.ClientSize = new System.Drawing.Size(813, 541);
            this.Controls.Add(this.tableLayoutPanelConnection);
            this.Controls.Add(this.tabControl);
            this.Controls.Add(this.statusStrip1);
            this.Controls.Add(this.menuStrip1);
            this.MainMenuStrip = this.menuStrip1;
            this.Name = "HIL_Interface";
            this.menuStrip1.ResumeLayout(false);
            this.menuStrip1.PerformLayout();
            this.statusStrip1.ResumeLayout(false);
            this.statusStrip1.PerformLayout();
            this.tabControl.ResumeLayout(false);
            this.tabPageRawData.ResumeLayout(false);
            this.tableLayoutPanelRawData.ResumeLayout(false);
            this.groupBoxRawXPlaneData.ResumeLayout(false);
            this.groupBoxRawXPlaneData.PerformLayout();
            this.groupBoxRawVexredusData.ResumeLayout(false);
            this.groupBoxRawVexredusData.PerformLayout();
            this.tabPageDecodedData.ResumeLayout(false);
            this.tableLayoutPanelData.ResumeLayout(false);
            this.groupBoxDataVexredus.ResumeLayout(false);
            this.tableLayoutPanelDataVexredus.ResumeLayout(false);
            this.groupBoxDataVexredusStatus.ResumeLayout(false);
            this.tableLayoutPanelDataVexredusStatus.ResumeLayout(false);
            this.tableLayoutPanelDataVexredusStatus.PerformLayout();
            this.groupBoxDataVexredusFlightControl.ResumeLayout(false);
            this.tableLayoutPanelDataVexredusFlightControl.ResumeLayout(false);
            this.tableLayoutPanelDataVexredusFlightControl.PerformLayout();
            this.groupBoxDataXPlane.ResumeLayout(false);
            this.tableLayoutPanelDataXPlane.ResumeLayout(false);
            this.groupBoxDataXPlaneFlightControl.ResumeLayout(false);
            this.tableLayoutPanelDataXPlaneFlightControl.ResumeLayout(false);
            this.tableLayoutPanelDataXPlaneFlightControl.PerformLayout();
            this.groupBoxDataXPlaneDataGPS.ResumeLayout(false);
            this.tableLayoutPanelDataXPlanePosition.ResumeLayout(false);
            this.tableLayoutPanelDataXPlanePosition.PerformLayout();
            this.groupBoxDataXPlaneStatus.ResumeLayout(false);
            this.tableLayoutPanelDataXPlaneStatus.ResumeLayout(false);
            this.tableLayoutPanelDataXPlaneStatus.PerformLayout();
            this.groupBoxDataXPlaneAttitude.ResumeLayout(false);
            this.tableLayoutPanelDataXPlaneAttitude.ResumeLayout(false);
            this.tableLayoutPanelDataXPlaneAttitude.PerformLayout();
            this.tabPageControls.ResumeLayout(false);
            this.tableLayoutPanelControls.ResumeLayout(false);
            this.groupBoxControlsXPlane.ResumeLayout(false);
            this.tableLayoutPanelControlsXPlane.ResumeLayout(false);
            this.groupBoxControlsXPlanePosition.ResumeLayout(false);
            this.tableLayoutPanelControlsXPlanePosition.ResumeLayout(false);
            this.tableLayoutPanelControlsXPlanePosition.PerformLayout();
            this.groupBoxControlsXPlaneFlightControl.ResumeLayout(false);
            this.tableLayoutPanelControlsFlightControl.ResumeLayout(false);
            this.tableLayoutPanelControlsFlightControl.PerformLayout();
            this.groupBoxControlsXPlaneAttitude.ResumeLayout(false);
            this.tableLayoutPanelControlsXPlaneAttitude.ResumeLayout(false);
            this.tableLayoutPanelControlsXPlaneAttitude.PerformLayout();
            this.tableLayoutPanelConnection.ResumeLayout(false);
            this.groupBoxConnectionXPlane.ResumeLayout(false);
            this.tableLayoutPanelConnectionXPlane.ResumeLayout(false);
            this.tableLayoutPanelConnectionXPlane.PerformLayout();
            this.groupBoxConnectionVexredus.ResumeLayout(false);
            this.tableLayoutPanelConnectionVexredus.ResumeLayout(false);
            this.tableLayoutPanelConnectionVexredus.PerformLayout();
            this.ResumeLayout(false);
            this.PerformLayout();

        }

        #region Buttons
        // Button events added from GUI Designer
        private void buttonControlsXPlanePositionSet_Click(object sender, EventArgs e)
        {
            try
            {
                // 20: lat, lon, altitude
                float lat = float.Parse(textBoxControlsXPlanePositionLatitude.Text);
                float lon = float.Parse(textBoxControlsXPlanePositionLongitude.Text);
                float alt_ftmsl = float.Parse(textBoxControlsXPlanePositionAltitude.Text);
                float NOT_USED = (float)-999;

                //float[] vars_out = { lat, lon, alt_ftmsl, NOT_USED, NOT_USED, NOT_USED, NOT_USED, NOT_USED };
                float[] vars_out = { lat, lon, NOT_USED, NOT_USED, NOT_USED, NOT_USED, NOT_USED, NOT_USED };
                XPlane_UDP_Message xmsg_out = new XPlane_UDP_Message("DATA", 20, vars_out);

                XPlaneSendMessage(xmsg_out);
            }
            catch (Exception ex)
            {
                this.XPlaneInputDisplayStatusText("Error: buttonControlsXPlanePositionSet_Click(): " + ex.Message);
                // DEBUGGING
                System.Console.WriteLine("Error: buttonControlsXPlanePositionSet_Click(): " + ex.Message);
            }
        }

        private void buttonControlsXPlaneAttitudeSet_Click(object sender, EventArgs e)
        {
            try
            {
                // 18: pitch, roll, headings
                float pitch = float.Parse(textBoxControlsXPlaneAttitudePitch.Text);
                float roll = float.Parse(textBoxControlsXPlaneAttitudeRoll.Text);
                float hding_true = float.Parse(textBoxControlsXPlaneAttitudeHeading.Text);
                float NOT_USED = (float)-999;

                float[] vars_out = { pitch, roll, hding_true, NOT_USED, NOT_USED, NOT_USED, NOT_USED, NOT_USED };
                XPlane_UDP_Message xmsg_out = new XPlane_UDP_Message("DATA", 18, vars_out);

                XPlaneSendMessage(xmsg_out);
            }
            catch (Exception ex)
            {
                this.XPlaneInputDisplayStatusText("Error: buttonControlsXPlanePositionSet_Click(): " + ex.Message);
                // DEBUGGING
                System.Console.WriteLine("Error: buttonControlsXPlanePositionSet_Click(): " + ex.Message);
            }

        }

        private void buttonControlsXPlaneFlightControlsSet_Click(object sender, EventArgs e)
        {
            try
            {
                float elev = float.Parse(textBoxControlsXPlaneFlightControlElevators.Text);
                float ailrn = float.Parse(textBoxControlsXPlaneFlightControlAilerons.Text);
                float ruddr = float.Parse(textBoxControlsXPlaneFlightControlRudder.Text);

                XPlaneSendMessageFlightControl(elev, ailrn, ruddr);
            }
            catch (Exception ex)
            {
                this.XPlaneInputDisplayStatusText("Error: buttonControlsXPlanePositionSet_Click(): " + ex.Message);
                // DEBUGGING
                System.Console.WriteLine("Error: buttonControlsXPlanePositionSet_Click(): " + ex.Message);
            }
        }

        private void connectionSettingsToolStripMenuItem_Click(object sender, EventArgs e)
        {
            HIL_Settings_Form settings = new HIL_Settings_Form(this);
            settings.ShowDialog();
        }

        private void aboutToolStripMenuItem_Click(object sender, EventArgs e)
        {
            HIL_About_Form about = new HIL_About_Form();
            about.ShowDialog();
        }

        private void exitButtonHandler(object sender, EventArgs e)
        {
            Close();
        }
        
        #endregion
    }
}

